Skip to content

Commit 870748f

Browse files
acmelnamhyung
authored andcommitted
perf tests hwmon_pmu: Remove double evlist__delete()
In the error path when failing to parse events the evlist is being deleted twice, keep the one after the out label. Fixes: 531ee0f ("perf test: Add hwmon "PMU" test") Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Link: https://lore.kernel.org/r/ZzzoJNNcJJVnPCCe@x1 Signed-off-by: Namhyung Kim <namhyung@kernel.org>
1 parent 5f2c8f4 commit 870748f

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

tools/perf/tests/hwmon_pmu.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,8 +155,6 @@ static int do_test(size_t i, bool with_pmu, bool with_alias)
155155
parse_events_error__init(&err);
156156
ret = parse_events(evlist, str, &err);
157157
if (ret) {
158-
evlist__delete(evlist);
159-
160158
pr_debug("FAILED %s:%d failed to parse event '%s', err %d\n",
161159
__FILE__, __LINE__, str, ret);
162160
parse_events_error__print(&err, str);

0 commit comments

Comments
 (0)