remus: resume immediately if libxl__xc_domain_save_done() completes
authorWen Congyang <wency@cn.fujitsu.com>
Tue, 19 Jan 2016 07:17:39 +0000 (15:17 +0800)
committerIan Campbell <ian.campbell@citrix.com>
Wed, 20 Jan 2016 17:09:48 +0000 (17:09 +0000)
commite73a85e0b45880b98406827d8478a20227977403
treeff54c24409d4b4ddc510bd5a8006a3bc52ac18b0
parent974af7db71fadb8456f17ae5a6ab40b80c48b3be
remus: resume immediately if libxl__xc_domain_save_done() completes

For example: if the secondary host is down, and we fail to send the data to
the secondary host. xc_domain_save() returns 0. So in the function
libxl__xc_domain_save_done(), rc is 0 (the helper program exits normally),
and retval is 0 (it is xc_domain_save()'s return value). In such case, we
just need to complete the stream.

Signed-off-by: Wen Congyang <wency@cn.fujitsu.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
[ ijc -- updated wording of comment as discussed ]
tools/libxl/libxl.h
tools/libxl/libxl_stream_write.c