aboutsummaryrefslogtreecommitdiff
path: root/gdb/dwarf2read.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/dwarf2read.c')
-rw-r--r--gdb/dwarf2read.c24
1 files changed, 14 insertions, 10 deletions
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
index a283cba..c185d51 100644
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -4221,14 +4221,13 @@ dwarf2_initialize_objfile (struct objfile *objfile)
void
dwarf2_build_psymtabs (struct objfile *objfile)
{
- volatile struct gdb_exception except;
if (objfile->global_psymbols.size == 0 && objfile->static_psymbols.size == 0)
{
init_psymbol_list (objfile, 1024);
}
- TRY_CATCH (except, RETURN_MASK_ERROR)
+ TRY
{
/* This isn't really ideal: all the data we allocate on the
objfile's obstack is still uselessly kept around. However,
@@ -4238,8 +4237,11 @@ dwarf2_build_psymtabs (struct objfile *objfile)
dwarf2_build_psymtabs_hard (objfile);
discard_cleanups (cleanups);
}
- if (except.reason < 0)
- exception_print (gdb_stderr, except);
+ CATCH (except, RETURN_MASK_ERROR)
+ {
+ exception_print (gdb_stderr, except);
+ }
+ END_CATCH
}
/* Return the total length of the CU described by HEADER. */
@@ -23171,16 +23173,18 @@ save_gdb_index_command (char *arg, int from_tty)
dwarf2_per_objfile = objfile_data (objfile, dwarf2_objfile_data_key);
if (dwarf2_per_objfile)
{
- volatile struct gdb_exception except;
- TRY_CATCH (except, RETURN_MASK_ERROR)
+ TRY
{
write_psymtabs_to_index (objfile, arg);
}
- if (except.reason < 0)
- exception_fprintf (gdb_stderr, except,
- _("Error while writing index for `%s': "),
- objfile_name (objfile));
+ CATCH (except, RETURN_MASK_ERROR)
+ {
+ exception_fprintf (gdb_stderr, except,
+ _("Error while writing index for `%s': "),
+ objfile_name (objfile));
+ }
+ END_CATCH
}
}
}