summaryrefslogtreecommitdiff
path: root/gdb/dbxread.c
diff options
context:
space:
mode:
authorTristan Gingold <gingold@adacore.com>2010-02-03 14:13:16 +0000
committerTristan Gingold <gingold@adacore.com>2010-02-03 14:13:16 +0000
commitd56f2f6a8db3b232c307c18074129e964528a7e2 (patch)
tree67b0e74d1d19fb45a7069f6d6c8100e7733120b5 /gdb/dbxread.c
parent1845978e84a2b5dbb403fb67a03d141c6176d17d (diff)
downloadgdb-d56f2f6a8db3b232c307c18074129e964528a7e2.tar.gz
2010-02-03 Tristan Gingold <gingold@adacore.com>
* symfile.h (struct sym_fns): Add sym_relocate field. (default_symfile_relocate): New prototype. (symfile_relocate_debug_section): First argument is now an objfile. * symfile.c (default_symfile_relocate): Rename from symfile_relocate_debug_section, first argument is now an objfile. (symfile_relocate_debug_section): New function. * coffread.c (coff_sym_fns): Set sym_relocate field. * somread.c (som_sym_fns): Ditto. * mipsread.c (ecoff_sym_fns): Ditto. * machoread.c (macho_sym_fns): Ditto. * elfread.c (elf_sym_fns): Ditto. * dwarf2read.c (dwarf2_read_section): Ditto. * xcoffread.c (xcoff_sym_fns): Ditto. * dbxread.c (aout_sym_fns): Ditto. (dbx_psymtab_to_symtab): Adjust call to symfile_relocate_debug_section. (elfstab_build_psymtabs): Ditto.
Diffstat (limited to 'gdb/dbxread.c')
-rw-r--r--gdb/dbxread.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gdb/dbxread.c b/gdb/dbxread.c
index 6ef676735e4..c9a575477fb 100644
--- a/gdb/dbxread.c
+++ b/gdb/dbxread.c
@@ -2473,7 +2473,7 @@ Shouldn't happen.\n",
if (DBX_STAB_SECTION (pst->objfile))
{
stabs_data
- = symfile_relocate_debug_section (pst->objfile->obfd,
+ = symfile_relocate_debug_section (pst->objfile,
DBX_STAB_SECTION (pst->objfile),
NULL);
if (stabs_data)
@@ -3460,7 +3460,7 @@ elfstab_build_psymtabs (struct objfile *objfile, asection *stabsect,
symbuf_read = 0;
symbuf_left = bfd_section_size (objfile->obfd, stabsect);
- stabs_data = symfile_relocate_debug_section (objfile->obfd, stabsect, NULL);
+ stabs_data = symfile_relocate_debug_section (objfile, stabsect, NULL);
if (stabs_data)
back_to = make_cleanup (free_current_contents, (void *) &stabs_data);
@@ -3571,6 +3571,7 @@ static struct sym_fns aout_sym_fns =
default_symfile_segments, /* sym_segments: Get segment information from
a file. */
NULL, /* sym_read_linetable */
+ default_symfile_relocate, /* sym_relocate: Relocate a debug section. */
NULL /* next: pointer to next struct sym_fns */
};