Expose virCapabilitiesFreeGuest

Guests are handled in callers, but if something goes wrong (when it
cannot be added to virCapabilities, for example), there's no way for
them to free it properly.

Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
This commit is contained in:
Martin Kletzander 2017-03-15 13:01:13 +01:00
parent 272d78a5ef
commit e8e9a7e9f7
3 changed files with 5 additions and 1 deletions

View File

@ -148,7 +148,7 @@ virCapabilitiesFreeGuestFeature(virCapsGuestFeaturePtr feature)
VIR_FREE(feature);
}
static void
void
virCapabilitiesFreeGuest(virCapsGuestPtr guest)
{
size_t i;

View File

@ -248,6 +248,9 @@ void
virCapabilitiesFreeMachines(virCapsGuestMachinePtr *machines,
int nmachines);
void
virCapabilitiesFreeGuest(virCapsGuestPtr guest);
virCapsGuestPtr
virCapabilitiesAddGuest(virCapsPtr caps,
int ostype,

View File

@ -53,6 +53,7 @@ virCapabilitiesAllocMachines;
virCapabilitiesClearHostNUMACellCPUTopology;
virCapabilitiesDomainDataLookup;
virCapabilitiesFormatXML;
virCapabilitiesFreeGuest;
virCapabilitiesFreeMachines;
virCapabilitiesFreeNUMAInfo;
virCapabilitiesGetCpusForNodemask;