|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-4.2-testing] xl/libxl: make shutdown accept the long option --wait for -w
# HG changeset patch
# User Sander Eikelenboom <linux@xxxxxxxxxxxxxx>
# Date 1351266490 -3600
# Node ID fa38bd96d904b54df895db3cc589926b787cdb01
# Parent fcd73195cf24175738135c144defcdb01fe74f37
xl/libxl: make shutdown accept the long option --wait for -w
Make xl/libxl accept the long option --wait for -w to be compatible with xm.
The long options are used in the default init and sysconfig scripts.
Signed-off-by: Sander Eikelenboom <linux@xxxxxxxxxxxxxx>
Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
Committed-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
xen-unstable changeset: 26045:ba7198bfc679
Backport-requested-by: Ian Campbell <Ian.Campbell@xxxxxxxxxx>
Committed-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
---
diff -r fcd73195cf24 -r fa38bd96d904 docs/man/xl.pod.1
--- a/docs/man/xl.pod.1 Fri Oct 26 16:47:57 2012 +0100
+++ b/docs/man/xl.pod.1 Fri Oct 26 16:48:10 2012 +0100
@@ -550,7 +550,7 @@ B<OPTIONS>
=over 4
-=item B<-w>
+=item B<-w>, B<--wait>
Wait for the domain to complete shutdown before returning.
diff -r fcd73195cf24 -r fa38bd96d904 tools/libxl/xl_cmdimpl.c
--- a/tools/libxl/xl_cmdimpl.c Fri Oct 26 16:47:57 2012 +0100
+++ b/tools/libxl/xl_cmdimpl.c Fri Oct 26 16:48:10 2012 +0100
@@ -3683,8 +3683,12 @@ int main_shutdown(int argc, char **argv)
int opt;
int wait = 0;
int fallback_trigger = 0;
-
- while ((opt = def_getopt(argc, argv, "wF", "shutdown", 1)) != -1) {
+ static struct option long_options[] = {
+ {"wait", 0, 0, 'w'},
+ {0, 0, 0, 0}
+ };
+
+ while ((opt = getopt_long(argc, argv, "wF", long_options, NULL)) != -1) {
switch (opt) {
case 0: case 2:
return opt;
diff -r fcd73195cf24 -r fa38bd96d904 tools/libxl/xl_cmdtable.c
--- a/tools/libxl/xl_cmdtable.c Fri Oct 26 16:47:57 2012 +0100
+++ b/tools/libxl/xl_cmdtable.c Fri Oct 26 16:48:10 2012 +0100
@@ -64,7 +64,7 @@ struct cmd_spec cmd_table[] = {
"-h Print this help.\n"
"-F Fallback to ACPI power event for HVM guests
with\n"
" no PV drivers.\n"
- "-w Wait for guest to shutdown.\n"
+ "-w, --wait Wait for guest to shutdown.\n"
},
{ "reboot",
&main_reboot, 0, 1,
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |