Commit b0f4ade1 authored by Fushuai Wang's avatar Fushuai Wang Committed by Arnaldo Carvalho de Melo
Browse files

perf trace: Fix IS_ERR() vs NULL check bug



The alloc_syscall_stats() function always returns an error pointer
(ERR_PTR) on failure.

So replace NULL check with IS_ERR() check after calling
alloc_syscall_stats() function.

Fixes: fc00897c ("perf trace: Add --summary-mode option")
Reviewed-by: default avatarIan Rogers <irogers@google.com>
Signed-off-by: default avatarFushuai Wang <wangfushuai@baidu.com>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Kan Liang <kan.liang@linux.intel.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent 0e9e7bc1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment