From 58ada01783ccac13e4ad86b71210d44e7084b8a5 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 23 Jan 2014 11:05:01 +0000 Subject: [PATCH] libvirt domain: Allow network drives with no elements. This is valid for some network drives: instead of this: Allow both forms. --- src/libvirt-domain.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/libvirt-domain.c b/src/libvirt-domain.c index ace2e00dd..af9770f38 100644 --- a/src/libvirt-domain.c +++ b/src/libvirt-domain.c @@ -541,8 +541,7 @@ for_each_disk (guestfs_h *g, xphost = xmlXPathEvalExpression (BAD_CAST "./source/host", xpathCtx); if (xphost == NULL || - xphost->nodesetval == NULL || - xphost->nodesetval->nodeNr == 0) + xphost->nodesetval == NULL) continue; /* This gives us a list of elements, which each have a