numactl/0010-fix-fix-memory-leaks-when-run-with-H.patch
chenhaixiang f7bc85f23b numactl: fix memory leaks when run with -H
signed-off-by:chenhaixiang3@huawei.com
2023-12-18 20:29:54 -05:00

28 lines
658 B
Diff

From 8daaae302b214539bba6b002c7c40b700ddcdc4b Mon Sep 17 00:00:00 2001
From: will_niutao <vincenttom@users.noreply.github.com>
Date: Thu, 24 Aug 2023 11:08:23 +0800
Subject: [PATCH] fix: fix memory leaks when run with -H
Conflict: NA
Reference: https://github.com/numactl/numactl/commit/8daaae302b214539bba6b002c7c40b700ddcdc4b
---
numactl.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/numactl.c b/numactl.c
index 47cbf39..562f319 100755
--- a/numactl.c
+++ b/numactl.c
@@ -242,6 +242,8 @@ static void print_node_cpus(int node)
printf(" %d", i);
}
putchar('\n');
+
+ numa_free_cpumask(cpus);
}
static void hardware(void)
--
2.39.3