From: Namhyung Kim Date: Tue, 27 Dec 2011 15:35:50 +0000 (+0900) Subject: perf top: Fix a memory leak X-Git-Tag: v3.3-rc1~51^2~15 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=057a174a064f68bac042d618ce3c6ea3ccd9a8aa;p=profile%2Fivi%2Fkernel-x86-ivi.git perf top: Fix a memory leak The 'buf' should be freed when symbol wasn't found too. Cc: Ingo Molnar Cc: Paul Mackerras Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/1325000151-4463-3-git-send-email-namhyung@gmail.com Signed-off-by: Namhyung Kim Signed-off-by: Arnaldo Carvalho de Melo --- diff --git a/tools/perf/builtin-top.c b/tools/perf/builtin-top.c index c3836b9..4f81eeb 100644 --- a/tools/perf/builtin-top.c +++ b/tools/perf/builtin-top.c @@ -351,7 +351,6 @@ static void perf_top__prompt_symbol(struct perf_top *top, const char *msg) if (!found) { fprintf(stderr, "Sorry, %s is not active.\n", buf); sleep(1); - return; } else perf_top__parse_source(top, found);