Skip to contentSkip to conversation

Fix xm dump-core : Doesn't unpause a domain if crash option is given

PATCH New Masaki Kanno 1 participant 1 message Sep 21, 2007

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Fix xm dump-core : Doesn't unpause a domain if crash option is given

Hi,

When xm dump-core command with crash option was executed, a domain is destroyed after the domain is unpaused. I think that unpausing is not necessary for the domain that is going to be destroyed.

This patch fixes xm dump-core command. When xm dump-core command with crash option was executed, it doesn't unpause the domain on the way.

Best regards,
Kan

tools/python/xen/xm/main.py +5 -5
diff -r a00cc97b392a tools/python/xen/xm/main.py
@@ -1292,13 +1292,13 @@ def xm_dump_core(args):
     try:
         print "Dumping core of domain: %s ..." % str(dom)
         server.xend.domain.dump(dom, filename, live, crash)
+
+        if crash:
+            print "Destroying domain: %s ..." % str(dom)
+            server.xend.domain.destroy(dom)
     finally:
-        if not live:
+        if not live and not crash:
             server.xend.domain.unpause(dom)
-
-    if crash:
-        print "Destroying domain: %s ..." % str(dom)
-        server.xend.domain.destroy(dom)
 
 def xm_rename(args):
     arg_check(args, "rename", 2)

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel