perf callchain: Check return value of fill_node()
authorNamhyung Kim <namhyung@kernel.org>
Tue, 16 Feb 2016 14:08:21 +0000 (23:08 +0900)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 19 Feb 2016 22:13:21 +0000 (19:13 -0300)
commit8451cbb9b174a9b6e016d7f1bff81ff12dbd1990
tree6268070f529b326230aa07a56064676345eff490
parent7565bd39c1a63c82350d26a66ea1a1f1bb49ad2e
perf callchain: Check return value of fill_node()

Memory allocation in the fill_node() can fail so change its return type
to int and check it in add_child() too.

Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Acked-by: Jiri Olsa <jolsa@kernel.org>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1455631723-17345-4-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/callchain.c