mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 21:55:25 +00:00
qemu: Fix possible memory leak in migration param processing
If virJSONValueArraySize(caps) <= 0, then we will still need to virJSONValueFree(caps) because qemuMonitorSetMigrationCapabilities won't consume it. Found by Coverity Signed-off-by: John Ferlan <jferlan@redhat.com>
This commit is contained in:
parent
6df5d77723
commit
6a6a5463af
@ -771,6 +771,7 @@ qemuMigrationParamsApply(virQEMUDriverPtr driver,
|
||||
migParams->params[xbzrle].set = true;
|
||||
|
||||
virJSONValueFree(params);
|
||||
virJSONValueFree(caps);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user