mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-24 22:55:23 +00:00
qemu: Fix typo in qemuDomainModifyDeviceFlags
One of our latest commits fbe87126
introduced this nasty typo:
func(vmdef, ...); where func() dereference vmdef->ncontrollers,
and vmdef was initialized to NULL. This leaves us with unconditional
immediate segfault. It should be vm->def instead.
This commit is contained in:
parent
b5c5ad365e
commit
e94c0a09ee
@ -5833,7 +5833,7 @@ qemuDomainModifyDeviceFlags(virDomainPtr dom, const char *xml,
|
||||
}
|
||||
|
||||
if (flags & VIR_DOMAIN_AFFECT_CONFIG) {
|
||||
if (virDomainDefCompatibleDevice(vmdef, dev) < 0)
|
||||
if (virDomainDefCompatibleDevice(vm->def, dev) < 0)
|
||||
goto endjob;
|
||||
|
||||
/* Make a copy for updated domain. */
|
||||
|
Loading…
Reference in New Issue
Block a user