summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2013-01-25 01:45:21 (GMT)
committerArnaldo Carvalho de Melo <acme@redhat.com>2013-01-25 15:49:29 (GMT)
commit56ab7140325c835c8bb53cf3bca0cf7b6e967f15 (patch)
tree5d3bf51c90c48ff391424dc7afa3af979346a5e4 /tools
parent2caa48a24061b1f8e8dab43ea3292a608a15e3c9 (diff)
downloadlinux-56ab7140325c835c8bb53cf3bca0cf7b6e967f15.tar.xz
perf ui browser: Free browser->helpline() on ui_browser__hide()
It is allocated at ui_browser__show(), so free it in its counterpart, ui_browser__hide(). Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Namhyung Kim <namhyung@gmail.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/n/tip-g449kvnbcpli4ceyxbe2jp1e@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/perf/ui/browser.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/perf/ui/browser.c b/tools/perf/ui/browser.c
index 588bcb2..809ea463 100644
--- a/tools/perf/ui/browser.c
+++ b/tools/perf/ui/browser.c
@@ -273,6 +273,8 @@ void ui_browser__hide(struct ui_browser *browser __maybe_unused)
{
pthread_mutex_lock(&ui__lock);
ui_helpline__pop();
+ free(browser->helpline);
+ browser->helpline = NULL;
pthread_mutex_unlock(&ui__lock);
}