mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-10-30 09:53:10 +00:00
qemu: replace VIR_FREE with g_free in all *Dispose() functions
Signed-off-by: Laine Stump <laine@redhat.com> Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
This commit is contained in:
parent
0ba9f66f3d
commit
67ee6c0a6a
@ -177,7 +177,7 @@ static void qemuAgentDispose(void *obj)
|
|||||||
if (agent->cb && agent->cb->destroy)
|
if (agent->cb && agent->cb->destroy)
|
||||||
(agent->cb->destroy)(agent, agent->vm);
|
(agent->cb->destroy)(agent, agent->vm);
|
||||||
virCondDestroy(&agent->notify);
|
virCondDestroy(&agent->notify);
|
||||||
VIR_FREE(agent->buffer);
|
g_free(agent->buffer);
|
||||||
g_main_context_unref(agent->context);
|
g_main_context_unref(agent->context);
|
||||||
virResetError(&agent->lastError);
|
virResetError(&agent->lastError);
|
||||||
}
|
}
|
||||||
|
@ -1982,12 +1982,12 @@ void virQEMUCapsDispose(void *obj)
|
|||||||
|
|
||||||
virBitmapFree(qemuCaps->flags);
|
virBitmapFree(qemuCaps->flags);
|
||||||
|
|
||||||
VIR_FREE(qemuCaps->package);
|
g_free(qemuCaps->package);
|
||||||
VIR_FREE(qemuCaps->kernelVersion);
|
g_free(qemuCaps->kernelVersion);
|
||||||
VIR_FREE(qemuCaps->binary);
|
g_free(qemuCaps->binary);
|
||||||
VIR_FREE(qemuCaps->hostCPUSignature);
|
g_free(qemuCaps->hostCPUSignature);
|
||||||
|
|
||||||
VIR_FREE(qemuCaps->gicCapabilities);
|
g_free(qemuCaps->gicCapabilities);
|
||||||
|
|
||||||
virSEVCapabilitiesFree(qemuCaps->sevCapabilities);
|
virSEVCapabilitiesFree(qemuCaps->sevCapabilities);
|
||||||
|
|
||||||
|
@ -306,78 +306,78 @@ static void virQEMUDriverConfigDispose(void *obj)
|
|||||||
virBitmapFree(cfg->namespaces);
|
virBitmapFree(cfg->namespaces);
|
||||||
|
|
||||||
g_strfreev(cfg->cgroupDeviceACL);
|
g_strfreev(cfg->cgroupDeviceACL);
|
||||||
VIR_FREE(cfg->uri);
|
g_free(cfg->uri);
|
||||||
|
|
||||||
VIR_FREE(cfg->configBaseDir);
|
g_free(cfg->configBaseDir);
|
||||||
VIR_FREE(cfg->configDir);
|
g_free(cfg->configDir);
|
||||||
VIR_FREE(cfg->autostartDir);
|
g_free(cfg->autostartDir);
|
||||||
VIR_FREE(cfg->logDir);
|
g_free(cfg->logDir);
|
||||||
VIR_FREE(cfg->swtpmLogDir);
|
g_free(cfg->swtpmLogDir);
|
||||||
VIR_FREE(cfg->stateDir);
|
g_free(cfg->stateDir);
|
||||||
VIR_FREE(cfg->swtpmStateDir);
|
g_free(cfg->swtpmStateDir);
|
||||||
VIR_FREE(cfg->slirpStateDir);
|
g_free(cfg->slirpStateDir);
|
||||||
VIR_FREE(cfg->dbusStateDir);
|
g_free(cfg->dbusStateDir);
|
||||||
|
|
||||||
VIR_FREE(cfg->libDir);
|
g_free(cfg->libDir);
|
||||||
VIR_FREE(cfg->cacheDir);
|
g_free(cfg->cacheDir);
|
||||||
VIR_FREE(cfg->saveDir);
|
g_free(cfg->saveDir);
|
||||||
VIR_FREE(cfg->snapshotDir);
|
g_free(cfg->snapshotDir);
|
||||||
VIR_FREE(cfg->checkpointDir);
|
g_free(cfg->checkpointDir);
|
||||||
VIR_FREE(cfg->channelTargetDir);
|
g_free(cfg->channelTargetDir);
|
||||||
VIR_FREE(cfg->nvramDir);
|
g_free(cfg->nvramDir);
|
||||||
|
|
||||||
VIR_FREE(cfg->defaultTLSx509certdir);
|
g_free(cfg->defaultTLSx509certdir);
|
||||||
VIR_FREE(cfg->defaultTLSx509secretUUID);
|
g_free(cfg->defaultTLSx509secretUUID);
|
||||||
|
|
||||||
VIR_FREE(cfg->vncTLSx509certdir);
|
g_free(cfg->vncTLSx509certdir);
|
||||||
VIR_FREE(cfg->vncTLSx509secretUUID);
|
g_free(cfg->vncTLSx509secretUUID);
|
||||||
VIR_FREE(cfg->vncListen);
|
g_free(cfg->vncListen);
|
||||||
VIR_FREE(cfg->vncPassword);
|
g_free(cfg->vncPassword);
|
||||||
VIR_FREE(cfg->vncSASLdir);
|
g_free(cfg->vncSASLdir);
|
||||||
|
|
||||||
VIR_FREE(cfg->spiceTLSx509certdir);
|
g_free(cfg->spiceTLSx509certdir);
|
||||||
VIR_FREE(cfg->spiceListen);
|
g_free(cfg->spiceListen);
|
||||||
VIR_FREE(cfg->spicePassword);
|
g_free(cfg->spicePassword);
|
||||||
VIR_FREE(cfg->spiceSASLdir);
|
g_free(cfg->spiceSASLdir);
|
||||||
|
|
||||||
VIR_FREE(cfg->chardevTLSx509certdir);
|
g_free(cfg->chardevTLSx509certdir);
|
||||||
VIR_FREE(cfg->chardevTLSx509secretUUID);
|
g_free(cfg->chardevTLSx509secretUUID);
|
||||||
|
|
||||||
VIR_FREE(cfg->vxhsTLSx509certdir);
|
g_free(cfg->vxhsTLSx509certdir);
|
||||||
VIR_FREE(cfg->vxhsTLSx509secretUUID);
|
g_free(cfg->vxhsTLSx509secretUUID);
|
||||||
|
|
||||||
VIR_FREE(cfg->nbdTLSx509certdir);
|
g_free(cfg->nbdTLSx509certdir);
|
||||||
VIR_FREE(cfg->nbdTLSx509secretUUID);
|
g_free(cfg->nbdTLSx509secretUUID);
|
||||||
|
|
||||||
VIR_FREE(cfg->migrateTLSx509certdir);
|
g_free(cfg->migrateTLSx509certdir);
|
||||||
VIR_FREE(cfg->migrateTLSx509secretUUID);
|
g_free(cfg->migrateTLSx509secretUUID);
|
||||||
|
|
||||||
VIR_FREE(cfg->backupTLSx509certdir);
|
g_free(cfg->backupTLSx509certdir);
|
||||||
VIR_FREE(cfg->backupTLSx509secretUUID);
|
g_free(cfg->backupTLSx509secretUUID);
|
||||||
|
|
||||||
while (cfg->nhugetlbfs) {
|
while (cfg->nhugetlbfs) {
|
||||||
cfg->nhugetlbfs--;
|
cfg->nhugetlbfs--;
|
||||||
VIR_FREE(cfg->hugetlbfs[cfg->nhugetlbfs].mnt_dir);
|
g_free(cfg->hugetlbfs[cfg->nhugetlbfs].mnt_dir);
|
||||||
}
|
}
|
||||||
VIR_FREE(cfg->hugetlbfs);
|
g_free(cfg->hugetlbfs);
|
||||||
VIR_FREE(cfg->bridgeHelperName);
|
g_free(cfg->bridgeHelperName);
|
||||||
VIR_FREE(cfg->prHelperName);
|
g_free(cfg->prHelperName);
|
||||||
VIR_FREE(cfg->slirpHelperName);
|
g_free(cfg->slirpHelperName);
|
||||||
VIR_FREE(cfg->dbusDaemonName);
|
g_free(cfg->dbusDaemonName);
|
||||||
|
|
||||||
VIR_FREE(cfg->saveImageFormat);
|
g_free(cfg->saveImageFormat);
|
||||||
VIR_FREE(cfg->dumpImageFormat);
|
g_free(cfg->dumpImageFormat);
|
||||||
VIR_FREE(cfg->snapshotImageFormat);
|
g_free(cfg->snapshotImageFormat);
|
||||||
VIR_FREE(cfg->autoDumpPath);
|
g_free(cfg->autoDumpPath);
|
||||||
|
|
||||||
g_strfreev(cfg->securityDriverNames);
|
g_strfreev(cfg->securityDriverNames);
|
||||||
|
|
||||||
VIR_FREE(cfg->lockManagerName);
|
g_free(cfg->lockManagerName);
|
||||||
|
|
||||||
virFirmwareFreeList(cfg->firmwares, cfg->nfirmwares);
|
virFirmwareFreeList(cfg->firmwares, cfg->nfirmwares);
|
||||||
|
|
||||||
VIR_FREE(cfg->memoryBackingDir);
|
g_free(cfg->memoryBackingDir);
|
||||||
VIR_FREE(cfg->swtpmStorageDir);
|
g_free(cfg->swtpmStorageDir);
|
||||||
|
|
||||||
g_strfreev(cfg->capabilityfilters);
|
g_strfreev(cfg->capabilityfilters);
|
||||||
}
|
}
|
||||||
|
@ -681,8 +681,8 @@ qemuDomainDiskPrivateDispose(void *obj)
|
|||||||
qemuDomainDiskPrivatePtr priv = obj;
|
qemuDomainDiskPrivatePtr priv = obj;
|
||||||
|
|
||||||
virObjectUnref(priv->migrSource);
|
virObjectUnref(priv->migrSource);
|
||||||
VIR_FREE(priv->qomName);
|
g_free(priv->qomName);
|
||||||
VIR_FREE(priv->nodeCopyOnRead);
|
g_free(priv->nodeCopyOnRead);
|
||||||
virObjectUnref(priv->blockjob);
|
virObjectUnref(priv->blockjob);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -771,8 +771,8 @@ qemuDomainVcpuPrivateDispose(void *obj)
|
|||||||
{
|
{
|
||||||
qemuDomainVcpuPrivatePtr priv = obj;
|
qemuDomainVcpuPrivatePtr priv = obj;
|
||||||
|
|
||||||
VIR_FREE(priv->type);
|
g_free(priv->type);
|
||||||
VIR_FREE(priv->alias);
|
g_free(priv->alias);
|
||||||
virJSONValueFree(priv->props);
|
virJSONValueFree(priv->props);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -890,7 +890,7 @@ qemuDomainGraphicsPrivateDispose(void *obj)
|
|||||||
{
|
{
|
||||||
qemuDomainGraphicsPrivatePtr priv = obj;
|
qemuDomainGraphicsPrivatePtr priv = obj;
|
||||||
|
|
||||||
VIR_FREE(priv->tlsAlias);
|
g_free(priv->tlsAlias);
|
||||||
g_clear_pointer(&priv->secinfo, qemuDomainSecretInfoFree);
|
g_clear_pointer(&priv->secinfo, qemuDomainSecretInfoFree);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -236,8 +236,8 @@ qemuMonitorDispose(void *obj)
|
|||||||
g_main_context_unref(mon->context);
|
g_main_context_unref(mon->context);
|
||||||
virResetError(&mon->lastError);
|
virResetError(&mon->lastError);
|
||||||
virCondDestroy(&mon->notify);
|
virCondDestroy(&mon->notify);
|
||||||
VIR_FREE(mon->buffer);
|
g_free(mon->buffer);
|
||||||
VIR_FREE(mon->balloonpath);
|
g_free(mon->balloonpath);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user