perf ui hist browser: Fix segfault on 'a' for annotate

There a typo in util/ui/browsers/hists.c that leads to a segfault when you
press the 'a' key on a non-resolved symbol (plain hex address).

LKML-Reference: <20100923201901.GE31726@gambetta>
Signed-off-by: Frederik Deweerdt <frederik.deweerdt@xprog.eu>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
Frederik Deweerdt 2010-09-23 22:19:01 +02:00 committed by Arnaldo Carvalho de Melo
parent 39cfae64df
commit c569d3326b

View File

@ -773,7 +773,7 @@ int hists__browse(struct hists *self, const char *helpline, const char *ev_name)
switch (key) {
case 'a':
if (browser->selection->map == NULL &&
if (browser->selection->map == NULL ||
browser->selection->map->dso->annotate_warned)
continue;
goto do_annotate;