mirror of https://gitee.com/openkylin/libvirt.git
qemu migration: avoid NULL-deref given an invalid input
* src/qemu/qemu_driver.c (doNonTunnelMigrate): Don't let a NULL "uri_out" provoke a NULL-dereference in doNativeMigrate: supply omitted goto-after-qemudReportError.
This commit is contained in:
parent
1428704d2a
commit
643ee3fa44
|
@ -7430,6 +7430,7 @@ static int doNonTunnelMigrate(virDomainPtr dom,
|
|||
if (uri_out == NULL) {
|
||||
qemudReportError(NULL, NULL, NULL, VIR_ERR_INTERNAL_ERROR, "%s",
|
||||
_("domainMigratePrepare2 did not set uri"));
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
if (doNativeMigrate(dom, driver, vm, uri_out, flags, dname, resource) < 0)
|
||||
|
|
Loading…
Reference in New Issue