libxl: fix POLLHUP handling
PATCH 1/1 libxl: fix POLLHUP handling
The current code in bootloader_copyfail will error out on expected POLLHUPs because of a missing "else" in the if clause.
The behaviour that triggers this bug has only been seen on FreeBSD so far.
---
Cc: Ian Jackson <[email protected]>
Cc: Wei Liu <[email protected]>
--- tools/libxl/libxl_bootloader.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
tools/libxl/libxl_bootloader.c +1 -2
@@ -591,8 +591,7 @@ static void bootloader_copyfail(libxl__egc *egc, const char *which, }else {LOG (ERROR ,"unexpected POLLHUP on %s" , which); } - } -if (!rc) { + }else if (!rc) {LOG (ERROR ,"unexpected eof copying %s" , which); rc =ERROR_FAIL ; }
Signature · 7 lines
2.6.4 (Apple Git-63) _______________________________________________ Xen-devel mailing list [email protected] http://lists.xen.org/xen-devel
Quoted 7 lines · Roger Pau Monne
The current code in
bootloader_copyfailwill error out on expected POLLHUPs because of a missing "else" in the if clause.The behaviour that triggers this bug has only been seen on FreeBSD so far.
Signed-off-by Roger Pau Monné <[email protected]>Suggested-by Ian Jackson <[email protected]>
Quoted 24 lines
---
Cc: Ian Jackson <[email protected]>
Cc: Wei Liu <[email protected]>--- tools/libxl/libxl_bootloader.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)tools/libxl/libxl_bootloader.c +1
-2@@ -591,8 +591,7 @@ static void bootloader_copyfail(libxl__egc *egc, const char *which, }else {LOG (ERROR ,"unexpected POLLHUP on %s" , which); } - } -if (!rc) { + }else if (!rc) {LOG (ERROR ,"unexpected eof copying %s" , which); rc =ERROR_FAIL ; }Signature · 1 line
2.6.4 (Apple Git-63)
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Ian Jackson
AppliedWei Liu writes ("Re: [PATCH] libxl: fix POLLHUP handling"):
Quoted 10 lines · Roger Pau Monne
Quoted 7 lines
The current code in
bootloader_copyfailwill error out on expected POLLHUPs because of a missing "else" in the if clause.The behaviour that triggers this bug has only been seen on FreeBSD so far.
Signed-off-by Roger Pau Monné <[email protected]>Suggested-by Ian Jackson <[email protected]>Acked-by Wei Liu <[email protected]>
Queued, thanks.
Ian.
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel