WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] xl: allow config filename to precede opti

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] xl: allow config filename to precede options
From: Xen patchbot-unstable <patchbot@xxxxxxx>
Date: Sat, 26 Feb 2011 07:40:11 +0000
Delivery-date: Fri, 25 Feb 2011 23:41:21 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
# Date 1298659428 0
# Node ID 8af88ff698ff8a4a42a10c92691f225c15aa8877
# Parent  3060ba3983ceb874df8d637dcda21a72f242f2c1
xl: allow config filename to precede options

"xm create" supports options which follow the domain config filename.
So xl should do as well.

This is an ad-hoc fixup to the "xl create" command line parser.  We
should revisit the xl command line parser in 4.2.

Signed-off-by: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Reported-by: W. Michael Petullo <mike@xxxxxxxx>
Committed-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
---


diff -r 3060ba3983ce -r 8af88ff698ff tools/libxl/xl_cmdimpl.c
--- a/tools/libxl/xl_cmdimpl.c  Fri Feb 25 18:41:34 2011 +0000
+++ b/tools/libxl/xl_cmdimpl.c  Fri Feb 25 18:43:48 2011 +0000
@@ -3253,6 +3253,11 @@
         {0, 0, 0, 0}
     };
 
+    if (argv[1] && argv[1][0] != '-' && !strchr(argv[1], '=')) {
+        filename = argv[1];
+        argc--; argv++;
+    }
+
     while (1) {
         opt = getopt_long(argc, argv, "hnqf:pcde", long_options, 
&option_index);
         if (opt == -1)

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] xl: allow config filename to precede options, Xen patchbot-unstable <=