1
0
mirror of https://gitlab.com/libvirt/libvirt.git synced 2025-01-10 05:17:59 +03:00

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 <eskultet@redhat.com>
This commit is contained in:
Erik Skultety 2018-03-06 09:20:58 +01:00
parent a32600f3ce
commit b4fad8ec16

View File

@ -7919,7 +7919,7 @@ qemuDomainUpdateDeviceLive(virDomainObjPtr vm,
break; break;
case VIR_DOMAIN_DEVICE_GRAPHICS: 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]; oldDev.data.graphics = vm->def->graphics[idx];
if (virDomainDefCompatibleDevice(vm->def, dev, &oldDev) < 0) if (virDomainDefCompatibleDevice(vm->def, dev, &oldDev) < 0)
return -1; return -1;