diff options
| author | Ian Rogers <[email protected]> | 2021-08-26 18:48:33 +0000 |
|---|---|---|
| committer | Arnaldo Carvalho de Melo <[email protected]> | 2021-08-31 18:12:00 +0000 |
| commit | 298105b78b0ede160c2b94293b86d4ba4e936ad5 (patch) | |
| tree | 8878e79d96963835d9d4385f55d46bd67b6bd1c4 /tools/perf/util/annotate.c | |
| parent | perf data: Correct -h output (diff) | |
| download | kernel-298105b78b0ede160c2b94293b86d4ba4e936ad5.tar.gz kernel-298105b78b0ede160c2b94293b86d4ba4e936ad5.zip | |
perf bpf: Fix memory leaks relating to BTF.
BTF needs to be freed with btf__free().
Signed-off-by: Ian Rogers <[email protected]>
Reviewed-by: Kajol Jain <[email protected]>
Cc: Alexander Shishkin <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Mark Rutland <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: Stephane Eranian <[email protected]>
Link: http://lore.kernel.org/lkml/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
Diffstat (limited to 'tools/perf/util/annotate.c')
| -rw-r--r-- | tools/perf/util/annotate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/util/annotate.c b/tools/perf/util/annotate.c index d43f6b5e5169..0bae061b2d6d 100644 --- a/tools/perf/util/annotate.c +++ b/tools/perf/util/annotate.c @@ -1833,7 +1833,7 @@ static int symbol__disassemble_bpf(struct symbol *sym, ret = 0; out: free(prog_linfo); - free(btf); + btf__free(btf); fclose(s); bfd_close(bfdf); return ret; |
