From: Ian Jackson Date: Thu, 13 Mar 2014 17:59:49 +0000 (+0000) Subject: tools/libxc: fix errno handling for HVM in xc_domain_save X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=29f0712bc008a9d6e611785424f797cfc185c1d3;p=people%2Froyger%2Fxen.git tools/libxc: fix errno handling for HVM in xc_domain_save The previous patch (dda0b77d "tools/libxc: pass errno to callers of xc_domain_save") did not jump to the proper label if the domU is HVM. Signed-off-by: Ian Jackson Reviewed-by: Olaf Hering --- diff --git a/tools/libxc/xc_domain_save.c b/tools/libxc/xc_domain_save.c index 9f96bb75e0..71f9b596d2 100644 --- a/tools/libxc/xc_domain_save.c +++ b/tools/libxc/xc_domain_save.c @@ -1836,8 +1836,7 @@ int xc_domain_save(xc_interface *xch, int io_fd, uint32_t dom, uint32_t max_iter } /* HVM guests are done now */ - errno = 0; - goto out; + goto success; } /* PV guests only from now on */ @@ -2037,6 +2036,7 @@ int xc_domain_save(xc_interface *xch, int io_fd, uint32_t dom, uint32_t max_iter } /* Success! */ + success: rc = errno = 0; goto out_rc;