Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(150)

Unified Diff: gdb/mipsread.c

Issue 124383005: GDB 7.6.50 (Closed) Base URL: http://git.chromium.org/native_client/nacl-gdb.git@upstream
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gdb/mipsnbsd-tdep.c ('k') | gdb/mn10300-linux-tdep.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gdb/mipsread.c
diff --git a/gdb/mipsread.c b/gdb/mipsread.c
index 23ceece652081b0f7f3202c483691f530800e4ab..d06d2f7c45d2c6f45f49e0af17c4b5d8e6feefae 100644
--- a/gdb/mipsread.c
+++ b/gdb/mipsread.c
@@ -1,7 +1,6 @@
/* Read a symbol table in MIPS' format (Third-Eye).
- Copyright (C) 1986-1987, 1989-1996, 1998-2001, 2003-2004, 2007-2012
- Free Software Foundation, Inc.
+ Copyright (C) 1986-2013 Free Software Foundation, Inc.
Contributed by Alessandro Forin (af@cs.cmu.edu) at CMU. Major work
by Per Bothner, John Gilmore and Ian Lance Taylor at Cygnus Support.
@@ -25,7 +24,7 @@
mdebugread.c. */
#include "defs.h"
-#include "gdb_string.h"
+#include <string.h>
#include "bfd.h"
#include "symtab.h"
#include "objfiles.h"
@@ -228,16 +227,28 @@ read_alphacoff_dynamic_symtab (struct section_offsets *section_offsets,
if (!bfd_get_section_contents (abfd, si.sym_sect, sym_secptr,
(file_ptr) 0, sym_secsize))
- return;
+ {
+ do_cleanups (cleanups);
+ return;
+ }
if (!bfd_get_section_contents (abfd, si.str_sect, str_secptr,
(file_ptr) 0, str_secsize))
- return;
+ {
+ do_cleanups (cleanups);
+ return;
+ }
if (!bfd_get_section_contents (abfd, si.dyninfo_sect, dyninfo_secptr,
(file_ptr) 0, dyninfo_secsize))
- return;
+ {
+ do_cleanups (cleanups);
+ return;
+ }
if (!bfd_get_section_contents (abfd, si.got_sect, got_secptr,
(file_ptr) 0, got_secsize))
- return;
+ {
+ do_cleanups (cleanups);
+ return;
+ }
/* Find the number of local GOT entries and the index for the
first dynamic symbol in the GOT. */
@@ -265,7 +276,10 @@ read_alphacoff_dynamic_symtab (struct section_offsets *section_offsets,
}
}
if (dt_mips_local_gotno < 0 || dt_mips_gotsym < 0)
- return;
+ {
+ do_cleanups (cleanups);
+ return;
+ }
/* Scan all dynamic symbols and enter them into the minimal symbol
table if appropriate. */
@@ -391,7 +405,6 @@ read_alphacoff_dynamic_symtab (struct section_offsets *section_offsets,
static const struct sym_fns ecoff_sym_fns =
{
- bfd_target_ecoff_flavour,
mipscoff_new_init, /* init anything gbl to entire symtab */
mipscoff_symfile_init, /* read initial info, setup for sym_read() */
mipscoff_symfile_read, /* read a symbol file into symtab */
@@ -411,5 +424,5 @@ void _initialize_mipsread (void);
void
_initialize_mipsread (void)
{
- add_symtab_fns (&ecoff_sym_fns);
+ add_symtab_fns (bfd_target_ecoff_flavour, &ecoff_sym_fns);
}
« no previous file with comments | « gdb/mipsnbsd-tdep.c ('k') | gdb/mn10300-linux-tdep.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698