aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorMatthew Daley <mattjd@gmail.com>2013-09-18 15:37:52 +1200
committerIan Campbell <ian.campbell@citrix.com>2013-09-25 12:56:08 +0100
commit1a0f10a8c8673ed62c7b0cff8f8de5b97c402b7d (patch)
tree4d0355744e5eb9926e5f64c80dd2387d2cf5c119 /tools
parent6b2b15ead2152fd541e2de494f50cf99e63bfb3d (diff)
downloadxen-1a0f10a8c8673ed62c7b0cff8f8de5b97c402b7d.tar.gz
xen-1a0f10a8c8673ed62c7b0cff8f8de5b97c402b7d.tar.bz2
xen-1a0f10a8c8673ed62c7b0cff8f8de5b97c402b7d.zip
libxl: fix file open failure check in libxl__file_reference_map
Coverity-ID: 1055567 Signed-off-by: Matthew Daley <mattjd@gmail.com> Acked-by: Ian Campbell <ian.campbell@citrix.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/libxl/libxl_internal.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/libxl/libxl_internal.c b/tools/libxl/libxl_internal.c
index 5a8cd38bf9..cf17658a7f 100644
--- a/tools/libxl/libxl_internal.c
+++ b/tools/libxl/libxl_internal.c
@@ -228,7 +228,7 @@ int libxl__file_reference_map(libxl__file_reference *f)
return 0;
fd = open(f->path, O_RDONLY);
- if (f < 0)
+ if (fd < 0)
return ERROR_FAIL;
ret = fstat(fd, &st_buf);