[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen master] libxl: fix file open failure check in libxl__file_reference_map



commit 1a0f10a8c8673ed62c7b0cff8f8de5b97c402b7d
Author:     Matthew Daley <mattjd@xxxxxxxxx>
AuthorDate: Wed Sep 18 15:37:52 2013 +1200
Commit:     Ian Campbell <ian.campbell@xxxxxxxxxx>
CommitDate: Wed Sep 25 12:56:08 2013 +0100

    libxl: fix file open failure check in libxl__file_reference_map
    
    Coverity-ID: 1055567
    Signed-off-by: Matthew Daley <mattjd@xxxxxxxxx>
    Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
---
 tools/libxl/libxl_internal.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/tools/libxl/libxl_internal.c b/tools/libxl/libxl_internal.c
index 5a8cd38..cf17658 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);
--
generated by git-patchbot for /home/xen/git/xen.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.