perf tools: Exit browser before printing usage when unkown option passed
authorArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 22 Mar 2010 16:10:29 +0000 (13:10 -0300)
committerIngo Molnar <mingo@elte.hu>
Mon, 22 Mar 2010 17:47:36 +0000 (18:47 +0100)
If not the screen will get garbled when using newt.

Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Frédéric Weisbecker <fweisbec@gmail.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Paul Mackerras <paulus@samba.org>
LKML-Reference: <1269274229-20442-5-git-send-email-acme@infradead.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
tools/perf/util/parse-options.c

index efebd5b476b320685178947332a48214d76529b5..79dfa0c34b3c6c84effca78654eb5b7d34f1314d 100644 (file)
@@ -500,6 +500,7 @@ int usage_with_options_internal(const char * const *usagestr,
 void usage_with_options(const char * const *usagestr,
                        const struct option *opts)
 {
+       exit_browser(false);
        usage_with_options_internal(usagestr, opts, 0);
        exit(129);
 }