mirror of
https://github.com/torvalds/linux.git
synced 2026-05-25 15:41:52 +02:00
perf dso: Add missed dso__put to dso__load_kcore
The kcore loading creates a set of list nodes that have reference
counted references to maps of the kcore. The list node freeing in the
success path wasn't releasing the maps, add the missing puts. It is
unclear why this leak was being missed by leak sanitizer.
Fixes: 8372020996 ("perf map: Move map list node into symbol")
Signed-off-by: Ian Rogers <irogers@google.com>
Link: https://lore.kernel.org/r/20250624190326.2038704-2-irogers@google.com
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
This commit is contained in:
parent
d4ae1620c6
commit
63a088e999
|
|
@ -1422,6 +1422,7 @@ static int dso__load_kcore(struct dso *dso, struct map *map,
|
|||
goto out_err;
|
||||
}
|
||||
}
|
||||
map__zput(new_node->map);
|
||||
free(new_node);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user