diff options
author | Sami Wagiaalla <swagiaal@redhat.com> | 2010-08-09 20:13:51 +0000 |
---|---|---|
committer | Sami Wagiaalla <swagiaal@redhat.com> | 2010-08-09 20:13:51 +0000 |
commit | 45c58896fccae96ae023059410027791537cb285 (patch) | |
tree | 90afe95f7ea77cfb0c72dbc1489444c030ce97a6 /gdb/symtab.c | |
parent | 776167e8fa07df96f999a0593f1dc536c80bc1cb (diff) | |
download | gdb-45c58896fccae96ae023059410027791537cb285.zip gdb-45c58896fccae96ae023059410027791537cb285.tar.gz gdb-45c58896fccae96ae023059410027791537cb285.tar.bz2 |
Fixed stabs cplus_specific issue
2010-08-09 Sami Wagiaalla <swagiaal@redhat.com>
* symtab.c (symbol_get_demangled_name): Remove assertion and
return NULL when language_specific.cplus_specific is not initialized.
* stabsread.c (define_symbol): Set the name before calling
cp_scan_for_anonymous_namespaces.
Diffstat (limited to 'gdb/symtab.c')
-rw-r--r-- | gdb/symtab.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gdb/symtab.c b/gdb/symtab.c index 5fbe58c..d43d573 100644 --- a/gdb/symtab.c +++ b/gdb/symtab.c @@ -382,8 +382,10 @@ symbol_get_demangled_name (const struct general_symbol_info *gsymbol) { if (gsymbol->language == language_cplus) { - gdb_assert (gsymbol->language_specific.cplus_specific != NULL); - return gsymbol->language_specific.cplus_specific->demangled_name; + if (gsymbol->language_specific.cplus_specific != NULL) + return gsymbol->language_specific.cplus_specific->demangled_name; + else + return NULL; } else return gsymbol->language_specific.mangled_lang.demangled_name; |