[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] tools: xend: fix wrong condition check for xml file
# HG changeset patch # User Joe Jin <joe.jin@xxxxxxxxxx> # Date 1350549308 -3600 # Node ID dd64a1bdbe3a2f141b729ee086016a3f40615daf # Parent 6239ace16749ae8f80a765d4b284ffec4153a05c tools: xend: fix wrong condition check for xml file In commit e8d40584, it intended to check xml file size and when empty will return, the condition should be "if os.path.getsize(xml_path) == 0" rather then "if not os.path.getsize(xml_path) == 0". Signed-off-by: Chuang Cao <chuang.cao@xxxxxxxxxx> Signed-off-by: Joe Jin <joe.jin@xxxxxxxxxx> Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx> Committed-by: Ian Campbell <ian.campbell@xxxxxxxxxx> --- diff -r 6239ace16749 -r dd64a1bdbe3a tools/python/xen/xend/XendStateStore.py --- a/tools/python/xen/xend/XendStateStore.py Thu Oct 18 09:35:07 2012 +0100 +++ b/tools/python/xen/xend/XendStateStore.py Thu Oct 18 09:35:08 2012 +0100 @@ -101,7 +101,7 @@ class XendStateStore: if not os.path.exists(xml_path): return {} - if not os.path.getsize(xml_path) == 0: + if os.path.getsize(xml_path) == 0: return {} dom = minidom.parse(xml_path) _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |