[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] libxl: qemu trad logdirty: Tolerate ENOENT on ret path
# HG changeset patch # User Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx> # Date 1355399041 0 # Node ID ef9242f5846f4b73e82bf6dec3a3991f53fe9b70 # Parent 69ec301b8ec20eacd3ebe87f56baca8b0e22c83f libxl: qemu trad logdirty: Tolerate ENOENT on ret path It can happen in error conditions that lds->ret_path doesn't exist, and libxl__xs_read_checked signals this by setting got_ret=NULL. If this happens, fail without crashing. Reported-by: Alex Bligh <alex@xxxxxxxxxxx>, Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx> Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx> Committed-by: Ian Campbell <ian.campbell@xxxxxxxxxx> --- diff -r 69ec301b8ec2 -r ef9242f5846f tools/libxl/libxl_dom.c --- a/tools/libxl/libxl_dom.c Thu Dec 13 11:44:01 2012 +0000 +++ b/tools/libxl/libxl_dom.c Thu Dec 13 11:44:01 2012 +0000 @@ -725,7 +725,7 @@ static void domain_suspend_switch_qemu_x rc = libxl__xs_read_checked(gc, t, lds->ret_path, &got_ret); if (rc) goto out; - if (strcmp(got, got_ret)) { + if (!got_ret || strcmp(got, got_ret)) { LOG(ERROR,"controlling logdirty: qemu was already sent" " command `%s' (xenstore path `%s') but result is `%s'", got, lds->cmd_path, got_ret ? got_ret : "<none>"); _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |