[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] Possible bug in function libxl.c interface in the function libxl_wait_for_memory_target()
Hi all,
The following code function might possibly return an incorrect value in the case of the target memory not meeting the required value after waiting for a given time period. Quoting the following lines from the xen git repositoryÂhttp://xenbits.xen.org/gitweb/?p=xen.git;a=blob;f=tools/libxl/libxl.c;h=77672d06bac0636c3c9f8d5ab0475ab796246f7c;hb=HEAD 4697 Â Â if ((info.current_memkb + info.outstanding_memkb) <= target_memkb) 4698 Â Â Â Â rc = 0; 4699 Â Â else 4700 Â Â Â Â rc = ERROR_FAIL; 4701Â 4702 out: 4703 Â Â return 0; 4704 } Here we calculate the return value and in the case of failure it should be ERROR_FAIL . However we still return the value 0. Thus possibly this function will still return 0 in the event of an error. Regards,
Ayush Ruia. _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |