提交 3d92a000 编写于 作者: C Cole Robinson

qemu: Fix crash when defining XML with bogus emulator

We weren't checking for failure of qemuCaps lookup
上级 79ba1076
......@@ -1247,7 +1247,9 @@ qemuDomainDefPostParse(virDomainDefPtr def,
!(def->emulator = virDomainDefGetDefaultEmulator(def, caps)))
return ret;
qemuCaps = virQEMUCapsCacheLookup(driver->qemuCapsCache, def->emulator);
if (!(qemuCaps = virQEMUCapsCacheLookup(driver->qemuCapsCache,
def->emulator)))
goto cleanup;
if (qemuDomainDefAddDefaultDevices(def, qemuCaps) < 0)
goto cleanup;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册