mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-23 21:34:54 +03:00
conf: eliminate virDomainNetDefClear()
This function is no longer used anywhere except virDomainNetDefFree(), so just inline its contents there. Signed-off-by: Laine Stump <laine@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
5bbf2fa7af
commit
47d622b560
@ -2491,7 +2491,7 @@ virDomainVsockDefFree(virDomainVsockDefPtr vsock)
|
||||
|
||||
|
||||
void
|
||||
virDomainNetDefClear(virDomainNetDefPtr def)
|
||||
virDomainNetDefFree(virDomainNetDefPtr def)
|
||||
{
|
||||
if (!def)
|
||||
return;
|
||||
@ -2566,14 +2566,7 @@ virDomainNetDefClear(virDomainNetDefPtr def)
|
||||
virNetDevBandwidthFree(def->bandwidth);
|
||||
def->bandwidth = NULL;
|
||||
virNetDevVlanClear(&def->vlan);
|
||||
}
|
||||
|
||||
void
|
||||
virDomainNetDefFree(virDomainNetDefPtr def)
|
||||
{
|
||||
if (!def)
|
||||
return;
|
||||
virDomainNetDefClear(def);
|
||||
virObjectUnref(def->privateData);
|
||||
VIR_FREE(def);
|
||||
}
|
||||
|
@ -3056,7 +3056,6 @@ void virDomainActualNetDefFree(virDomainActualNetDefPtr def);
|
||||
virDomainVsockDefPtr virDomainVsockDefNew(virDomainXMLOptionPtr xmlopt);
|
||||
void virDomainVsockDefFree(virDomainVsockDefPtr vsock);
|
||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(virDomainVsockDef, virDomainVsockDefFree);
|
||||
void virDomainNetDefClear(virDomainNetDefPtr def);
|
||||
void virDomainNetDefFree(virDomainNetDefPtr def);
|
||||
void virDomainSmartcardDefFree(virDomainSmartcardDefPtr def);
|
||||
void virDomainChrDefFree(virDomainChrDefPtr def);
|
||||
|
@ -507,7 +507,6 @@ virDomainNetARPInterfaces;
|
||||
virDomainNetBandwidthUpdate;
|
||||
virDomainNetDefActualFromNetworkPort;
|
||||
virDomainNetDefActualToNetworkPort;
|
||||
virDomainNetDefClear;
|
||||
virDomainNetDefFormat;
|
||||
virDomainNetDefFree;
|
||||
virDomainNetDefNew;
|
||||
|
Loading…
Reference in New Issue
Block a user