[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-3.2-testing] Fix xm save command's #params check.



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1204733734 0
# Node ID 243fd1b2e296047ddcd3273e778af43d31024172
# Parent  94498a5d9ce01dcf37033bb8906096e6171fd6c8
Fix xm save command's #params check.
Signed-off-by: Masaki Kanno <kanno.masaki@xxxxxxxxxxxxxx>
xen-unstable changeset:   17132:bfd87849ccda6db8bd7b336b5230237683af96ee
xen-unstable date:        Wed Feb 27 13:19:42 2008 +0000
---
 tools/python/xen/xm/main.py |    9 +++------
 1 files changed, 3 insertions(+), 6 deletions(-)

diff -r 94498a5d9ce0 -r 243fd1b2e296 tools/python/xen/xm/main.py
--- a/tools/python/xen/xm/main.py       Wed Mar 05 16:14:59 2008 +0000
+++ b/tools/python/xen/xm/main.py       Wed Mar 05 16:15:34 2008 +0000
@@ -690,9 +690,6 @@ def xm_save(args):
         err(opterr)
         sys.exit(1)
 
-    dom = params[0]
-    savefile = params[1]
-
     checkpoint = False
     for (k, v) in options:
         if k in ['-c', '--checkpoint']:
@@ -701,9 +698,9 @@ def xm_save(args):
     if len(params) != 2:
         err("Wrong number of parameters")
         usage('save')
-        sys.exit(1)
-
-    savefile = os.path.abspath(savefile)
+
+    dom = params[0]
+    savefile = os.path.abspath(params[1])
 
     if not os.access(os.path.dirname(savefile), os.W_OK):
         err("xm save: Unable to create file %s" % savefile)

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.