From 5068b8e88dfae4eb3142eb19e8f599e7ba9f85ef Mon Sep 17 00:00:00 2001 From: matt rice Date: Sat, 27 Aug 2011 10:28:31 +0000 Subject: * solib-sunos.c (allocate_rt_common_objfile): Add missing arguments to bcache_xmalloc, replace bcache_xmalloc with call to psymbol_bcache_init for psymbol_cache. * symfile.c (reread_symbols): Remove extra calls to bcache_xmalloc. --- gdb/ChangeLog | 7 +++++++ gdb/solib-sunos.c | 6 +++--- gdb/symfile.c | 3 --- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index e2bd6f6..896e16d 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,10 @@ +2011-08-26 Matt Rice + + * solib-sunos.c (allocate_rt_common_objfile): Add missing arguments to + bcache_xmalloc, replace bcache_xmalloc with call to + psymbol_bcache_init for psymbol_cache. + * symfile.c (reread_symbols): Remove extra calls to bcache_xmalloc. + 2011-08-26 Jan Kratochvil * inf-loop.c (inferior_event_handler): Add exception_print in diff --git a/gdb/solib-sunos.c b/gdb/solib-sunos.c index 405ca4f..28e9a21 100644 --- a/gdb/solib-sunos.c +++ b/gdb/solib-sunos.c @@ -189,9 +189,9 @@ allocate_rt_common_objfile (void) objfile = (struct objfile *) xmalloc (sizeof (struct objfile)); memset (objfile, 0, sizeof (struct objfile)); - objfile->psymbol_cache = bcache_xmalloc (); - objfile->macro_cache = bcache_xmalloc (); - objfile->filename_cache = bcache_xmalloc (); + objfile->psymbol_cache = psymbol_bcache_init (); + objfile->macro_cache = bcache_xmalloc (NULL, NULL); + objfile->filename_cache = bcache_xmalloc (NULL, NULL); obstack_init (&objfile->objfile_obstack); objfile->name = xstrdup ("rt_common"); diff --git a/gdb/symfile.c b/gdb/symfile.c index aca907a..bb233c9 100644 --- a/gdb/symfile.c +++ b/gdb/symfile.c @@ -2472,9 +2472,6 @@ reread_symbols (void) memset (&objfile->msymbol_demangled_hash, 0, sizeof (objfile->msymbol_demangled_hash)); - objfile->psymbol_cache = psymbol_bcache_init (); - objfile->macro_cache = bcache_xmalloc (NULL, NULL); - objfile->filename_cache = bcache_xmalloc (NULL, NULL); /* obstack_init also initializes the obstack so it is empty. We could use obstack_specify_allocation but gdb_obstack.h specifies the alloc/dealloc -- cgit v1.1