From: Erik Skultety Date: Tue, 6 Mar 2018 08:20:58 +0000 (+0100) Subject: qemu: Fix comparison assignment in qemuDomainUpdateDeviceLive X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=b4fad8ec16ed5c3959df4135108b544b5e44282d;p=libvirt.git qemu: Fix comparison assignment in qemuDomainUpdateDeviceLive Fix this common typo and assign a value rather than implicitly type-casted comparison result. Introduced by commit b6a264e855. Signed-off-by: Erik Skultety --- diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index 96454c17c0..9e715e7a00 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -7919,7 +7919,7 @@ qemuDomainUpdateDeviceLive(virDomainObjPtr vm, break; case VIR_DOMAIN_DEVICE_GRAPHICS: - if ((idx = qemuDomainFindGraphicsIndex(vm->def, dev->data.graphics) >= 0)) { + if ((idx = qemuDomainFindGraphicsIndex(vm->def, dev->data.graphics)) >= 0) { oldDev.data.graphics = vm->def->graphics[idx]; if (virDomainDefCompatibleDevice(vm->def, dev, &oldDev) < 0) return -1;