qemu: avoid leaking uninit data from hotplug to dumpxml
Detected by Coverity. The fix in 2c27dfae didn't catch all bad instances of memcpy(). Thankfully, on further analysis, all of the problematic uses are only triggered by old qemu that lacks -device. * src/qemu/qemu_hotplug.c (qemuDomainAttachPciDiskDevice) (qemuDomainAttachNetDevice, qemuDomainAttachHostPciDevice): Init all fields since monitor only populates some of them.
Showing
想要评论请 注册 或 登录