[PATCH v2 0/3] perf: Clean up and fix potential mem leak

From: Shang XiaoJing
Date: Mon Sep 05 2022 - 22:54:59 EST


Some clean up in perf.c and builtin-c2c.c.

changes from v2:
- clear omissible free label in c2c_he_zalloc.

Shang XiaoJing (3):
perf clean: Add same_cmd_with_prefix helper
perf c2c: Add helpers to get counts of loads or stores
perf c2c: Prevent potential memory leak in c2c_he_zalloc

tools/perf/builtin-c2c.c | 77 +++++++++++++++++++---------------------
tools/perf/perf.c | 12 +++++--
2 files changed, 46 insertions(+), 43 deletions(-)

--
2.17.1