diff options
| author | Ian Rogers <[email protected]> | 2024-02-09 19:17:43 -0800 |
|---|---|---|
| committer | Namhyung Kim <[email protected]> | 2024-02-12 12:35:33 -0800 |
| commit | 107ef66cb054f8d54e336236a31631a8cc167c1f (patch) | |
| tree | d3b67ab8a3a16e344c3b05d1023bd80a2fa144d0 /tools/perf/scripts/python/bin | |
| parent | 42fd623b58dbcc48310705bbf3e3d4d7c1deec29 (diff) | |
perf maps: Get map before returning in maps__find_by_name
Finding a map is done under a lock, returning the map without a
reference count means it can be removed without notice and causing
uses after free. Grab a reference count to the map within the lock
region and return this. Fix up locations that need a map__put
following this. Also fix some reference counted pointer comparisons.
Signed-off-by: Ian Rogers <[email protected]>
Acked-by: Namhyung Kim <[email protected]>
Cc: K Prateek Nayak <[email protected]>
Cc: James Clark <[email protected]>
Cc: Vincent Whitchurch <[email protected]>
Cc: Alexey Dobriyan <[email protected]>
Cc: Colin Ian King <[email protected]>
Cc: Changbin Du <[email protected]>
Cc: Masami Hiramatsu <[email protected]>
Cc: Song Liu <[email protected]>
Cc: Leo Yan <[email protected]>
Cc: Athira Rajeev <[email protected]>
Cc: Liam Howlett <[email protected]>
Cc: Artem Savkov <[email protected]>
Cc: [email protected]
Signed-off-by: Namhyung Kim <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions