From a806e5c1ba5af340e4ab09c0b0410e89c8fcc628 Mon Sep 17 00:00:00 2001 Message-Id: <a806e5c1ba5af340e4ab09c0b0410e89c8fcc628.1283420935.git.jdenemar@redhat.com> From: Laine Stump <laine@redhat.com> Date: Thu, 29 Jul 2010 09:41:33 -0400 Subject: [PATCH] Eliminate memory leak in xenUnifiedDomainInfoListFree This fixes a leak described in https://bugzilla.redhat.com/show_bug.cgi?id=590073 xenUnifiedDomainInfoList has a pointer to a list of pointers to xenUnifiedDomain. We were freeing up all the domains, but neglecting to free the list. This was found by Paolo Bonzini <pbonzini@redhat.com>. (cherry picked from commit 1999e4f8f880c33307254096a01765594fdfd1d0) --- src/xen/xen_driver.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/src/xen/xen_driver.c b/src/xen/xen_driver.c index 4afb252..a14e2b5 100644 --- a/src/xen/xen_driver.c +++ b/src/xen/xen_driver.c @@ -2044,6 +2044,7 @@ xenUnifiedDomainInfoListFree(xenUnifiedDomainInfoListPtr list) VIR_FREE(list->doms[i]->name); VIR_FREE(list->doms[i]); } + VIR_FREE(list->doms); VIR_FREE(list); } -- 1.7.2.2