mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-08 03:40:35 +09:00
perf pmu: zfree() expects a pointer to a pointer to zero it after freeing its contents
An audit showed just this one problem with zfree(), fix it.
Fixes: 9fbc61f832 ("perf pmu: Add support for PMU capabilities")
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
@@ -1852,7 +1852,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);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user