perf symbols: Check if a struct machine instance was found
authorArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 10 May 2010 00:14:07 +0000 (21:14 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 10 May 2010 00:14:07 +0000 (21:14 -0300)
commit4cc4945844fe2cf493f1783b6ce938ba1617d5c2
treed4d94f2f4447acf93473ec47de1ef5851fca9f00
parent3ceb0d4438876a65606c258e5d69e03e57460dd6
perf symbols: Check if a struct machine instance was found

Which can happen when processing old files that had no fake kernel MMAP,
events.

That shouldn't result in perf_session__create_kernel_maps not being
called, this will be fixed in a followup patch, for now do these checks
to avoid segfaulting.

Cc: Frédéric Weisbecker <fweisbec@gmail.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Tom Zanussi <tzanussi@gmail.com>
LKML-Reference: <new-submission>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/event.c