diff options
author | Namhyung Kim <namhyung@kernel.org> | 2017-02-17 17:17:38 +0900 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2017-02-20 11:35:54 -0300 |
commit | bb963e16507ca7670f0bb47ccaada8874b2ba6a1 (patch) | |
tree | f031d2d30e418588ebf323d85f749a14894d6e39 /tools/perf/util/stat.c | |
parent | 80df1988201ac6648609eba13d48aef9f7974c10 (diff) | |
download | talos-op-linux-bb963e16507ca7670f0bb47ccaada8874b2ba6a1.tar.gz talos-op-linux-bb963e16507ca7670f0bb47ccaada8874b2ba6a1.zip |
perf utils: Check verbose flag properly
It now can have negative value to suppress the message entirely. So it
needs to check it being positive.
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: kernel-team@lge.com
Link: http://lkml.kernel.org/r/20170217081742.17417-3-namhyung@kernel.org
[ Adjust fuzz on tools/perf/util/pmu.c, add > 0 checks in many other places ]
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/stat.c')
-rw-r--r-- | tools/perf/util/stat.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/util/stat.c b/tools/perf/util/stat.c index 39345c2ddfc2..0d51334a9b46 100644 --- a/tools/perf/util/stat.c +++ b/tools/perf/util/stat.c @@ -344,7 +344,7 @@ int perf_stat_process_counter(struct perf_stat_config *config, for (i = 0; i < 3; i++) update_stats(&ps->res_stats[i], count[i]); - if (verbose) { + if (verbose > 0) { fprintf(config->output, "%s: %" PRIu64 " %" PRIu64 " %" PRIu64 "\n", perf_evsel__name(counter), count[0], count[1], count[2]); } |