xl: Handle return value from libxl_domain_suspend correctly
authorIan Jackson <ian.jackson@eu.citrix.com>
Thu, 28 Jun 2012 17:43:26 +0000 (18:43 +0100)
committerIan Jackson <ian.jackson@eu.citrix.com>
Thu, 28 Jun 2012 17:43:26 +0000 (18:43 +0100)
libxl_domain_suspend returns a libxl error code.  So it must be
wrapped with MUST and not CHK_ERRNO.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <Ian.Jackson@eu.citrix.com>
tools/libxl/xl_cmdimpl.c

index bcdef00e0266ed38e072ef4e4cfc220e9f45e5cf..1029e6c2c8f4025e5a99faea47ead0538d06dec8 100644 (file)
@@ -2826,7 +2826,7 @@ static int save_domain(const char *p, const char *filename, int checkpoint,
 
     save_domain_core_writeconfig(fd, filename, config_data, config_len);
 
-    CHK_ERRNO(libxl_domain_suspend(ctx, domid, fd, 0, NULL));
+    MUST(libxl_domain_suspend(ctx, domid, fd, 0, NULL));
     close(fd);
 
     if (checkpoint)