summaryrefslogtreecommitdiffstats
path: root/tools/perf/builtin-report.c
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2010-04-02 10:04:18 -0300
committerArnaldo Carvalho de Melo <acme@redhat.com>2010-04-02 16:28:31 -0300
commitad5b217b152d99ca3922153500c619d9758dd87a (patch)
treee0377f6f1de3394d29babe49c24a0152df18000d /tools/perf/builtin-report.c
parentb9fb93047756c5e4129dfda7591612de61b0e877 (diff)
downloadop-kernel-dev-ad5b217b152d99ca3922153500c619d9758dd87a.zip
op-kernel-dev-ad5b217b152d99ca3922153500c619d9758dd87a.tar.gz
perf session: Remove one more exit() call from library code
Return NULL instead and make the caller propagate the error. LKML-Reference: <new-submission> 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> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/builtin-report.c')
-rw-r--r--tools/perf/builtin-report.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/perf/builtin-report.c b/tools/perf/builtin-report.c
index 1fb13e5..6767f10 100644
--- a/tools/perf/builtin-report.c
+++ b/tools/perf/builtin-report.c
@@ -89,9 +89,12 @@ static int perf_session__add_hist_entry(struct perf_session *self,
struct event_stat_id *stats;
struct perf_event_attr *attr;
- if ((sort__has_parent || symbol_conf.use_callchain) && data->callchain)
+ if ((sort__has_parent || symbol_conf.use_callchain) && data->callchain) {
syms = perf_session__resolve_callchain(self, al->thread,
data->callchain, &parent);
+ if (syms == NULL)
+ return -ENOMEM;
+ }
attr = perf_header__find_attr(data->id, &self->header);
if (attr)
OpenPOWER on IntegriCloud