perf symbols: Initialize dso->loaded
authorArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 3 Nov 2009 17:52:18 +0000 (15:52 -0200)
committerIngo Molnar <mingo@elte.hu>
Tue, 3 Nov 2009 17:56:06 +0000 (18:56 +0100)
Brown paper bag bug introduced in:

 66bd8424cc05e800db384053bf7ab967e4658468 ("perf tools: Delay
 loading symtabs till we hit a map with it")

Without this we were not loading any symtabs that happened to be
on a DSO for which the allocated memory for ->loaded was !0.

Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Mike Galbraith <efault@gmx.de>
LKML-Reference: <1257270738-5669-1-git-send-email-acme@infradead.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
tools/perf/util/symbol.c

index cf2c7f7..93c49f4 100644 (file)
@@ -121,6 +121,7 @@ struct dso *dso__new(const char *name)
                self->find_symbol = dso__find_symbol;
                self->slen_calculated = 0;
                self->origin = DSO__ORIG_NOT_FOUND;
+               self->loaded = false;
        }
 
        return self;