mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 10:40:03 +01:00
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@oracle.com>
Signed-off-by: Joe Jin <joe.jin@oracle.com>
Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Committed-by: Ian Campbell <ian.campbell@citrix.com>
This commit is contained in:
1 parent
3623f8abe0
commit
191e485a19
1 file changed
+1
-1
@@ -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)
|
||||
|
||||