[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH] libxl: prevent xl from running if xend is running.
On Mon, 2012-04-23 at 16:11 +0100, Roger Pau Monne wrote: > @@ -112,6 +116,9 @@ int main(int argc, char **argv) > case 'N': > dryrun_only = 1; > break; > + case 'f': > + force_execution = 1; > + break; > default: > fprintf(stderr, "unknown global option\n"); > exit(2); Needs a matching docs patch to add the option to the manpage. Otherwise: Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx> > @@ -126,6 +133,15 @@ int main(int argc, char **argv) > } > opterr = 0; > > + for (int i = 0; i < sizeof(locks)/sizeof(locks[0]); i++) { > + if (!access(locks[i], F_OK) && !force_execution) { > + fprintf(stderr, "xend is running, which prevents xl from working > " > + "correctly. If you still want to force the " > + "execution of xl please use the -f option\n"); You might as well wrap the output text to 80 columns (I didn't count, I assume this isn't...) > + exit(2); > + } > + } > + _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |