Searched hist:"25 feb605fe3b2674142d084379e0737a99945aba" (Results 1 – 1 of 1) sorted by relevance
/linux/tools/perf/util/ |
H A D | parse-events.c | diff 25feb605fe3b2674142d084379e0737a99945aba Wed Apr 12 14:50:08 CEST 2023 Arnaldo Carvalho de Melo <acme@redhat.com> perf parse-events: Use zfree() to reduce chances of use after free
Do defensive programming by using zfree() to initialize freed pointers to NULL, so that eventual use after free result in a NULL pointer deref instead of more subtle behaviour.
Also remove one NULL test before free(), as it accepts a NULL arg and we get one line shaved not doing it explicitely.
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
|