From: Peter Krempa Date: Mon, 26 Aug 2013 12:34:56 +0000 (+0200) Subject: qemu: Don't update count of vCPUs if hot-plug fails silently X-Git-Tag: v1.1.2-rc1~38 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f17f164e3acefd590437da84cdcf08c63c7abb0b;p=thirdparty%2Flibvirt.git qemu: Don't update count of vCPUs if hot-plug fails silently When cpu hotplug fails without reporting an error, we would fail the command but update the count of vCPUs anyways. Commit 761fc481365703b861429d73a341bde352ba8d41 fixed the case when CPU hot-unplug failed silently, but forgot to fix up the value in this case. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1000357 --- diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index 0a8e518dd6..c39f04d010 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -3982,6 +3982,7 @@ static int qemuDomainHotplugVcpus(virQEMUDriverPtr driver, _("got wrong number of vCPU pids from QEMU monitor. " "got %d, wanted %d"), ncpupids, vcpus); + vcpus = oldvcpus; ret = -1; goto cleanup; }