[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH 3 of 3] xl: Remove global domid and enable -Wshadow
On Fri, 2012-09-14 at 13:42 +0100, Ian Campbell wrote: > I find it hard to believe I won't have broken anything here... I > tested basic lifecycle ops only. I should have taken this bet :-/ Incremental fixup to the patch below... (could be folded in) 8<-------------------------------------------------- xl: make sure we always use the result of find_domain This is a leftover from when domid was a global. Annotate it with want_unused_result and fix the handful of errors. Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx> diff -r 8fad3481f8c9 tools/libxl/xl_cmdimpl.c --- a/tools/libxl/xl_cmdimpl.c Fri Sep 14 13:40:49 2012 +0100 +++ b/tools/libxl/xl_cmdimpl.c Fri Sep 14 13:45:23 2012 +0100 @@ -195,6 +195,7 @@ static int cpupool_qualifier_to_cpupooli return was_name ? libxl_name_to_cpupoolid(ctx, p, poolid_r) : 0; } +static uint32_t find_domain(const char *p) __attribute__((warn_unused_result)); static uint32_t find_domain(const char *p) { uint32_t domid; @@ -5807,7 +5808,7 @@ int main_tmem_freeze(int argc, char **ar if (all) domid = INVALID_DOMID; else - find_domain(dom); + domid = find_domain(dom); libxl_tmem_freeze(ctx, domid); return 0; @@ -5840,7 +5841,7 @@ int main_tmem_thaw(int argc, char **argv if (all) domid = INVALID_DOMID; else - find_domain(dom); + domid = find_domain(dom); libxl_tmem_thaw(ctx, domid); return 0; @@ -5887,7 +5888,7 @@ int main_tmem_set(int argc, char **argv) if (all) domid = INVALID_DOMID; else - find_domain(dom); + domid = find_domain(dom); if (!opt_w && !opt_c && !opt_p) { fprintf(stderr, "No set value specified.\n\n"); @@ -5942,7 +5943,7 @@ int main_tmem_shared_auth(int argc, char if (all) domid = INVALID_DOMID; else - find_domain(dom); + domid = find_domain(dom); if (uuid == NULL || autharg == NULL) { fprintf(stderr, "No uuid or auth specified.\n\n"); _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |