mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-09-09 01:04:59 +00:00
qemuInitPasswords: avoid unconditional leak
* src/qemu/qemu_driver.c (qemuInitPasswords): Free pass-phrase buffer.
This commit is contained in:
parent
bc6a48c6cf
commit
309647c81f
@ -1758,6 +1758,7 @@ qemuInitPasswords(virConnectPtr conn,
|
||||
ret = qemuMonitorSetDrivePassphrase(priv->mon,
|
||||
vm->def->disks[i]->info.alias,
|
||||
secret);
|
||||
VIR_FREE(secret);
|
||||
qemuDomainObjExitMonitorWithDriver(driver, vm);
|
||||
if (ret < 0)
|
||||
goto cleanup;
|
||||
|
Loading…
Reference in New Issue
Block a user