mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 13:45:38 +00:00
qemuMigrationCookieAddCaps: Use 'g_new0' instead of VIR_ALLOC
Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
83434e5acd
commit
78d330bde1
@ -542,8 +542,7 @@ qemuMigrationCookieAddCaps(qemuMigrationCookiePtr mig,
|
||||
qemuDomainObjPrivatePtr priv = vm->privateData;
|
||||
|
||||
qemuMigrationCookieCapsFree(mig->caps);
|
||||
if (VIR_ALLOC(mig->caps) < 0)
|
||||
return -1;
|
||||
mig->caps = g_new0(qemuMigrationCookieCaps, 1);
|
||||
|
||||
if (priv->migrationCaps)
|
||||
mig->caps->supported = virBitmapNewCopy(priv->migrationCaps);
|
||||
|
Loading…
Reference in New Issue
Block a user