From 8112a7114bbc5a98ec2069a28e1aae1de98ff99e Mon Sep 17 00:00:00 2001 From: Jim Kingdon Date: Wed, 17 Mar 1993 04:07:29 +0000 Subject: [PATCH] * xcoffexec.c (add_vmap): Wrap symbol read in catch_errors. --- gdb/ChangeLog | 12 ++++++++++++ gdb/xcoffexec.c | 22 ++++++++++++++++++---- 2 files changed, 30 insertions(+), 4 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 6471567f343..bb0e931996f 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,15 @@ +Tue Mar 16 15:18:17 1993 Jim Kingdon (kingdon@cygnus.com) + + * xcoffexec.c (add_vmap): Wrap symbol read in catch_errors. + + * xcoffread.c (read_symbol_lineno): Look to end of symbols for .bf, + not just 50 symbols. + (symtbl_num_syms): New variable. + (read_xcoff_symtab): Set it. + (read_symbol_nvalue): Check for bad symno. + (read_symbol_{lineno,nvalue}, callers): Don't pass symtable; it's + always symtbl. + Tue Mar 16 10:09:05 1993 Stu Grossman (grossman@cygnus.com) * config/rs6000.mh: Get rid of -Dfd_set=int crock. diff --git a/gdb/xcoffexec.c b/gdb/xcoffexec.c index 96bd97f0f3c..db658e0308e 100644 --- a/gdb/xcoffexec.c +++ b/gdb/xcoffexec.c @@ -465,6 +465,17 @@ CORE_ADDR old_start; } } +/* Add symbols for an objfile. */ +static int +objfile_symbol_add (arg) + char *arg; +{ + struct objfile *obj = (struct objfile *) arg; + syms_from_objfile (obj, 0, 0, 0); + new_symfile_objfile (obj, 0, 0); + return 1; +} + static struct vmap *add_vmap PARAMS ((struct ld_info *)); /* Add a new vmap entry based on ldinfo() information. @@ -540,10 +551,13 @@ add_vmap(ldi) vp->objfile = obj; #ifndef SOLIB_SYMBOLS_MANUAL - syms_from_objfile (obj, 0, 0, 0); - new_symfile_objfile (obj, 0, 0); - vmap_symtab (vp, 0, 0); - vp->loaded = 1; + if (catch_errors (objfile_symbol_add, (char *)obj, + "Error while reading shared library symbols:\n")) + { + /* Note this is only done if symbol reading was successful. */ + vmap_symtab (vp, 0, 0); + vp->loaded = 1; + } #endif return vp; } -- 2.30.2