When adding CPU usability blockers I forgot to properly free them when
in virDomainCapsCPUModelsDispose.
Reported-by: Marc Hartmayer <mhartmay(a)linux.vnet.ibm.com>
Signed-off-by: Jiri Denemark <jdenemar(a)redhat.com>
---
src/conf/domain_capabilities.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/conf/domain_capabilities.c b/src/conf/domain_capabilities.c
index 729d905e2..7f96ff386 100644
--- a/src/conf/domain_capabilities.c
+++ b/src/conf/domain_capabilities.c
@@ -94,8 +94,10 @@ virDomainCapsCPUModelsDispose(void *obj)
virDomainCapsCPUModelsPtr cpuModels = obj;
size_t i;
- for (i = 0; i < cpuModels->nmodels; i++)
+ for (i = 0; i < cpuModels->nmodels; i++) {
VIR_FREE(cpuModels->models[i].name);
+ virStringListFree(cpuModels->models[i].blockers);
+ }
VIR_FREE(cpuModels->models);
}
--
2.14.3