]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
perf tools: Make Ctrl-C stop processing on TUI
authorNamhyung Kim <namhyung@kernel.org>
Fri, 29 May 2015 12:53:44 +0000 (21:53 +0900)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 29 May 2015 15:49:00 +0000 (12:49 -0300)
commited426915900db3c58c410b8b38f6ff0e46bf6c96
tree754aa0939698ea7cc04587ee0b10be323fc9c64d
parentd7a3d85e08477a979933a2bb3b525a8de99543c2
perf tools: Make Ctrl-C stop processing on TUI

It was inconvenient that perf cannot be quit with SIGINT during
processing samples on TUI especially for large data files.

This was because the first argument of SLang_init_tty(), abort_char,
being 0.  The manual says it's the ascii value of the control character
that will be used to generate the interrupt signal [1].  Passing -1
means to use the default value (Ctrl-C).

However, after processing samples, Ctrl-C was used to in other cases as
well - like stepping back from annotate.  So recover the original
behavior after processing.

[1] http://jedsoft.org/slang/doc/html/cslang-6.html#ss6.1

Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1432904024-13170-1-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/ui/browsers/annotate.c
tools/perf/ui/browsers/hists.c
tools/perf/ui/tui/setup.c