From: Peter Krempa Date: Wed, 22 Oct 2014 09:27:36 +0000 (+0200) Subject: qemu: migration: Make check for empty hook XML robust X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=19b1ee42b49b2764f7df23787f4b6022886a612c;p=libvirt.git qemu: migration: Make check for empty hook XML robust Also consider whitespace only strings returned from the hook as empty result. --- diff --git a/src/qemu/qemu_migration.c b/src/qemu/qemu_migration.c index e135249fe2..ca70e35294 100644 --- a/src/qemu/qemu_migration.c +++ b/src/qemu/qemu_migration.c @@ -2570,7 +2570,7 @@ qemuMigrationPrepareAny(virQEMUDriverPtr driver, if (hookret < 0) { goto cleanup; } else if (hookret == 0) { - if (!*xmlout) { + if (virStringIsEmpty(xmlout)) { VIR_DEBUG("Migrate hook filter returned nothing; using the" " original XML"); } else {