perf tools: Fix TUI helpline output
authorArnaldo Carvalho de Melo <[email protected]>
Thu, 29 Nov 2012 19:51:01 +0000 (16:51 -0300)
committerArnaldo Carvalho de Melo <[email protected]>
Sun, 9 Dec 2012 11:46:07 +0000 (08:46 -0300)
In commit e2f4351 "perf ui/helpline: Introduce ui_helpline__vshow()" the
test for the browser used made ui_helpline__vshow() to be called only
for the GTK browser.

The TUI one then was not used and vfprintf(stderr, ...) was used
instead, making the TUI scroll the screen instead of just printing on
the last line.

Fix it by doing the proper check, that is to call ui_helpline__vshow to
be called for both the TUI and GTK browsers.

Cc: David Ahern <[email protected]>
Cc: Frederic Weisbecker <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Mike Galbraith <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: Stephane Eranian <[email protected]>
Link: http://lkml.kernel.org/n/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
tools/perf/util/debug.c

index 391c9a9e946fb4c3f012fda5d88cda78506ef550..399e74c34c1aa5220ecc29bd0d33cca2d2a3ac82 100644 (file)
@@ -23,7 +23,7 @@ int eprintf(int level, const char *fmt, ...)
 
        if (verbose >= level) {
                va_start(args, fmt);
-               if (use_browser > 1)
+               if (use_browser >= 1)
                        ui_helpline__vshow(fmt, args);
                else
                        ret = vfprintf(stderr, fmt, args);