mirror of https://gitee.com/openkylin/libvirt.git
Fix reference leak in remoteDispatchStorageVolCreateXmlFrom
This commit is contained in:
parent
27ba0ad905
commit
e2692e25de
daemon
|
@ -4118,12 +4118,15 @@ remoteDispatchStorageVolCreateXmlFrom (struct qemud_server *server ATTRIBUTE_UNU
|
|||
|
||||
clonevol = get_nonnull_storage_vol (conn, args->clonevol);
|
||||
if (clonevol == NULL) {
|
||||
virStoragePoolFree(pool);
|
||||
remoteDispatchConnError(rerr, conn);
|
||||
return -1;
|
||||
}
|
||||
|
||||
newvol = virStorageVolCreateXMLFrom (pool, args->xml, clonevol,
|
||||
args->flags);
|
||||
virStorageVolFree(clonevol);
|
||||
virStoragePoolFree(pool);
|
||||
if (newvol == NULL) {
|
||||
remoteDispatchConnError(rerr, conn);
|
||||
return -1;
|
||||
|
|
Loading…
Reference in New Issue