Greg Padgett has uploaded a new change for review. Change subject: vm: Fix exception when shutdown() called on vm in 'Down' state ......................................................................
vm: Fix exception when shutdown() called on vm in 'Down' state Attempting to call the shutdown() method on a VM which is in 'Down' state resulted in an exception if called through xmlrpclib. Instead, adopt the convention used by similar APIs such as migrate() and return errCode['noVM']. Change-Id: I8b75d0b869354d503e5f187e33370b5837b3c698 Bug-Url: https://bugzilla.redhat.com/1027297 Signed-off-by: Greg Padgett <[email protected]> --- M vdsm/vm.py 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/37/21937/1 diff --git a/vdsm/vm.py b/vdsm/vm.py index e8d5954..4ff5e27 100644 --- a/vdsm/vm.py +++ b/vdsm/vm.py @@ -2488,7 +2488,7 @@ try: now = time.time() if self.lastStatus == 'Down': - return + return errCode['noVM'] if self.guestAgent and self.guestAgent.isResponsive(): self._guestEventTime = now self._guestEvent = 'Powering down' -- To view, visit http://gerrit.ovirt.org/21937 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I8b75d0b869354d503e5f187e33370b5837b3c698 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Greg Padgett <[email protected]> _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
