[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH]xl: Check dom0 on command level when destroy domains
Check dom0 on command level when destroy domains. Signed-off-by: Yang Hongyang<yanghy@xxxxxxxxxxxxxx> diff -r 0a0bdb02600b tools/libxl/xl_cmdimpl.c --- a/tools/libxl/xl_cmdimpl.c Tue May 18 22:48:00 2010 +0800 +++ b/tools/libxl/xl_cmdimpl.c Tue May 18 22:51:16 2010 +0800 @@ -1568,6 +1568,10 @@ { int rc; find_domain(p); + if (domid == 0) { + fprintf(stderr, "Cannot destroy privileged domain 0.\n\n"); + exit(-1); + } rc = libxl_domain_destroy(&ctx, domid, 0); if (rc) { fprintf(stderr,"destroy failed (rc=%d)\n.",rc); exit(-1); } } -- Regards Yang Hongyang _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |