aboutsummaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo2023-04-12 10:23:35 -0300
committerGreg Kroah-Hartman2023-05-17 11:53:39 +0200
commitd592598f4775831cabfd665f22da736caabfac4f (patch)
tree6b965498dbda7dc8e6ad258710bbe94795f70950 /tools
parent36a840a86278962e2f121b9a9ac42936ebe301bf (diff)
perf pmu: zfree() expects a pointer to a pointer to zero it after freeing its contents
[ Upstream commit 57f14b5ae1a97537f2abd2828ee7212cada7036e ] An audit showed just this one problem with zfree(), fix it. Fixes: 9fbc61f832ebf432 ("perf pmu: Add support for PMU capabilities") Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'tools')
-rw-r--r--tools/perf/util/pmu.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/util/pmu.c b/tools/perf/util/pmu.c
index 03284059175f..9a762c0cc53c 100644
--- a/tools/perf/util/pmu.c
+++ b/tools/perf/util/pmu.c
@@ -1845,7 +1845,7 @@ static int perf_pmu__new_caps(struct list_head *list, char *name, char *value)
return 0;
free_name:
- zfree(caps->name);
+ zfree(&caps->name);
free_caps:
free(caps);