[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH V5 06/32] libxl: fix memory leak in libxl_cpuid_dispose
libxl_cpuid_policy_list is not allocated with GC-aware allocation so it needs to be freed manually, just like what libxl_string_list_dispose and libxl_key_value_list_dispose do. Signed-off-by: Wei Liu <wei.liu2@xxxxxxxxxx> Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx> --- tools/libxl/libxl_cpuid.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/libxl/libxl_cpuid.c b/tools/libxl/libxl_cpuid.c index d1ea50d..3787213 100644 --- a/tools/libxl/libxl_cpuid.c +++ b/tools/libxl/libxl_cpuid.c @@ -26,6 +26,7 @@ void libxl_cpuid_dispose(libxl_cpuid_policy_list *p_cpuid_list) if (cpuid_list[i].policy[j] != NULL) free(cpuid_list[i].policy[j]); } + free(cpuid_list); return; } -- 1.7.10.4 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |