[et-mgmt-tools] [PATCH] virt-manager: fix errorpath in domain.py

Guido Guenther agx at sigxcpu.org
Thu Dec 20 15:56:55 UTC 2007


Hi,
trivial patch against version 0.5.2 for fixing the error path, otherwise
libvirtError is unknown to the interpreter. Please apply:

diff --git a/src/virtManager/domain.py b/src/virtManager/domain.py
index 513f857..323a478 100644
--- a/src/virtManager/domain.py
+++ b/src/virtManager/domain.py
@@ -681,7 +681,7 @@ class vmmDomain(gobject.GObject):
         try:
             if self.is_active():
                 self.vm.attachDevice(xml)
-        except libvirtError, e:
+        except libvirt.libvirtError, e:
             device_exception = str(e)
 
         index = vmxml.find("</devices>")
@@ -703,7 +703,7 @@ class vmmDomain(gobject.GObject):
         if self.is_active():
             try:
                 self.vm.detachDevice(dev_xml)
-            except libvirtError, e:
+            except libvirt.libvirtError, e:
                 device_exception = str(e)
 
         # then the stored XML

Cheers,
 -- Guido




More information about the et-mgmt-tools mailing list