Re: [PATCH v2 2/2] perf metric: Fix some memory leaks - part 2

2020-09-06 Thread Jiri Olsa
On Sat, Sep 05, 2020 at 11:19:12AM +0900, Namhyung Kim wrote: > The metric_event_delete() missed to free expr->metric_events and it > should free an expr when metric_refs allocation failed. > > Cc: Kajol Jain > Cc: John Garry > Cc: Ian Rogers > Fixes: 4ea2896715e67 ("perf metric: Collect refere

[PATCH v2 2/2] perf metric: Fix some memory leaks - part 2

2020-09-04 Thread Namhyung Kim
The metric_event_delete() missed to free expr->metric_events and it should free an expr when metric_refs allocation failed. Cc: Kajol Jain Cc: John Garry Cc: Ian Rogers Fixes: 4ea2896715e67 ("perf metric: Collect referenced metrics in struct metric_expr") Signed-off-by: Namhyung Kim --- tool