mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 18:50:05 +01:00
bitkeeper revision 1.1159.6.6 (41179dabYIpxIUZuaPwVjF-Fu7boXA)
Fix restore to have correct arguments.
This commit is contained in:
1 parent
9b9aa8ef37
commit
21e0d175ee
1 file changed
+5
-9
@@ -282,17 +282,13 @@ class ProgRestore(Prog):
|
||||
info = """Create a domain from a saved state."""
|
||||
|
||||
def help(self, args):
|
||||
print args[0], "FILE [CONFIG]"
|
||||
print "\nRestore a domain from FILE using configuration CONFIG."
|
||||
print args[0], "FILE"
|
||||
print "\nRestore a domain from FILE."
|
||||
|
||||
def main(self, help, args):
|
||||
def main(self, args):
|
||||
if len(args) < 2: self.err("%s: Missing arguments" % args[0])
|
||||
savefile = os.path.abspath(args[1])
|
||||
if len(args) >= 3:
|
||||
configfile = os.path.abspath(args[2])
|
||||
else:
|
||||
configfile = None
|
||||
info = server.xend_domain_restore(savefile, configfile)
|
||||
savefile = os.path.abspath(args[1])
|
||||
info = server.xend_domain_restore(savefile)
|
||||
PrettyPrint.prettyprint(info)
|
||||
|
||||
xm.prog(ProgRestore)
|
||||
|
||||