[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH] tools/libxl: Correctly check if libxl_get_scheduler has failed
Hi Ian, On 03/20/2014 01:23 PM, Ian Jackson wrote: > Julien Grall writes ("[PATCH] tools/libxl: Correctly check if > libxl_get_scheduler has failed"): >> libxl_get_scheduler will return an enum, therefore checking if the value >> is negative is wrong. > > Gah. enums in C are so hateful. > >> - if ((sched = libxl_get_scheduler(ctx)) < 0) { >> + if ((int)(sched = libxl_get_scheduler(ctx)) < 0) { > > I'm afraid this isn't the right fix. The right fix is not to use the > enum type at all. libxl_get_scheduler, and the "sched" local, should > be ints. Thanks. I will rework the patch. Regards, -- Julien Grall _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |