提交 f30672d5 编写于 作者: J John Ferlan

qemu: Remove dead code

Since commit id '20a0fa8e' removed the QEMU_CAPS_DEVICE, Coverity notes
that it's no longer possible to have 'addrs' be NULL when checking for
a live domain since qemuDomainPCIAddressSetCreate would have jumped to
cleanup if addrs was NULL.
上级 54f325e9
...@@ -1614,15 +1614,11 @@ qemuDomainAssignPCIAddresses(virDomainDefPtr def, ...@@ -1614,15 +1614,11 @@ qemuDomainAssignPCIAddresses(virDomainDefPtr def,
if (obj && obj->privateData) { if (obj && obj->privateData) {
priv = obj->privateData; priv = obj->privateData;
if (addrs) { /* if this is the live domain object, we persist the PCI addresses */
/* if this is the live domain object, we persist the PCI addresses*/ virDomainPCIAddressSetFree(priv->pciaddrs);
virDomainPCIAddressSetFree(priv->pciaddrs); priv->persistentAddrs = 1;
priv->persistentAddrs = 1; priv->pciaddrs = addrs;
priv->pciaddrs = addrs; addrs = NULL;
addrs = NULL;
} else {
priv->persistentAddrs = 0;
}
} }
ret = 0; ret = 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册