diff options
Diffstat (limited to 'gdb/minsyms.c')
-rw-r--r-- | gdb/minsyms.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/gdb/minsyms.c b/gdb/minsyms.c index 8ac5014..18cf672 100644 --- a/gdb/minsyms.c +++ b/gdb/minsyms.c @@ -1291,6 +1291,27 @@ install_minimal_symbols (struct objfile *objfile) } } +/* See minsyms.h. */ + +void +terminate_minimal_symbol_table (struct objfile *objfile) +{ + if (! objfile->msymbols) + objfile->msymbols = ((struct minimal_symbol *) + obstack_alloc (&objfile->objfile_obstack, + sizeof (objfile->msymbols[0]))); + + { + struct minimal_symbol *m + = &objfile->msymbols[objfile->minimal_symbol_count]; + + memset (m, 0, sizeof (*m)); + /* Don't rely on these enumeration values being 0's. */ + MSYMBOL_TYPE (m) = mst_unknown; + SYMBOL_SET_LANGUAGE (m, language_unknown); + } +} + /* Sort all the minimal symbols in OBJFILE. */ void |