<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<p>Reviewed-By: Ramon Medeiros <a class="moz-txt-link-rfc2396E" href="mailto:ramonn@br.ibm.com"><ramonn@br.ibm.com></a><br>
</p>
<br>
<div class="moz-cite-prefix">On 12/12/2016 12:14 PM,
<a class="moz-txt-link-abbreviated" href="mailto:bianca@linux.vnet.ibm.com">bianca@linux.vnet.ibm.com</a> wrote:<br>
</div>
<blockquote
cite="mid:1481552043-86644-1-git-send-email-bianca@linux.vnet.ibm.com"
type="cite">
<pre wrap="">From: Bianca Carvalho <a class="moz-txt-link-rfc2396E" href="mailto:bianca@linux.vnet.ibm.com"><bianca@linux.vnet.ibm.com></a>
Changed "registerAttachDevicesEvent" in model/libvirtevents.py file
to include AttributeError as a exception to make sure kimchi will
be running even if this exception is true.
Also fixed indentation in vms.py file.
Signed-off-by: Bianca Carvalho <a class="moz-txt-link-rfc2396E" href="mailto:bianca@linux.vnet.ibm.com"><bianca@linux.vnet.ibm.com></a>
---
model/libvirtevents.py | 2 +-
model/vms.py | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/model/libvirtevents.py b/model/libvirtevents.py
index 2dd9904..716420c 100644
--- a/model/libvirtevents.py
+++ b/model/libvirtevents.py
@@ -101,7 +101,7 @@ class LibvirtEvents(object):
cb,
arg)
- except libvirt.libvirtError as e:
+ except (AttributeError, libvirt.libvirtError), e:
wok_log.error("register attach event failed: %s" % e.message)
def registerDetachDevicesEvent(self, conn, cb, arg):
diff --git a/model/vms.py b/model/vms.py
index d703c89..d6f8020 100644
--- a/model/vms.py
+++ b/model/vms.py
@@ -1108,7 +1108,7 @@ class VMModel(object):
def update_cpu_live(self, dom, vcpus):
flags = libvirt.VIR_DOMAIN_AFFECT_LIVE | \
- libvirt.VIR_DOMAIN_AFFECT_CONFIG
+ libvirt.VIR_DOMAIN_AFFECT_CONFIG
try:
dom.setVcpusFlags(vcpus, flags)
except libvirt.libvirtError as e:
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Ramon Nunes Medeiros
Kimchi Developer
Linux Technology Center Brazil
IBM Systems & Technology Group
Phone : +55 19 2132 7878
<a class="moz-txt-link-abbreviated" href="mailto:ramonn@br.ibm.com">ramonn@br.ibm.com</a> </pre>
</body>
</html>