diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2010-05-15 20:06:58 -0400 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2010-05-15 20:06:58 -0400 |
commit | 29351db6a05e7e42be457569428425520a18beec (patch) | |
tree | fc6bb2bd3a4b371f41fd7ee698fbdcaac4bf94a3 /tools | |
parent | c1ec5fefd9cd9ccb020966a49a3c7f44b25d9e84 (diff) |
perf newt: Exit browser unconditionally when CTRL+C, q or Q is pressed
ESC still asks for confirmation.
Suggested-by: Ingo Molnar <mingo@elte.hu>
Cc: Frédéric Weisbecker <fweisbec@gmail.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Tom Zanussi <tzanussi@gmail.com>
LKML-Reference: <new-submission>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools')
-rw-r--r-- | tools/perf/util/newt.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tools/perf/util/newt.c b/tools/perf/util/newt.c index 094887f45d05..139eb1a16cd8 100644 --- a/tools/perf/util/newt.c +++ b/tools/perf/util/newt.c | |||
@@ -837,9 +837,10 @@ int hists__browse(struct hists *self, const char *helpline, const char *input_na | |||
837 | if (es.reason == NEWT_EXIT_HOTKEY) { | 837 | if (es.reason == NEWT_EXIT_HOTKEY) { |
838 | if (toupper(es.u.key) == 'A') | 838 | if (toupper(es.u.key) == 'A') |
839 | goto do_annotate; | 839 | goto do_annotate; |
840 | if (es.u.key == NEWT_KEY_ESCAPE || | 840 | if (toupper(es.u.key) == 'Q' || |
841 | toupper(es.u.key) == 'Q' || | 841 | es.u.key == CTRL('c')) |
842 | es.u.key == CTRL('c')) { | 842 | break; |
843 | if (es.u.key == NEWT_KEY_ESCAPE) { | ||
843 | if (dialog_yesno("Do you really want to exit?")) | 844 | if (dialog_yesno("Do you really want to exit?")) |
844 | break; | 845 | break; |
845 | else | 846 | else |