aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1995-07-05 20:54:57 +0000
committerIan Lance Taylor <ian@airs.com>1995-07-05 20:54:57 +0000
commit6c495350ae7a6db62b04322a88b061d7491677a3 (patch)
tree9ea0c40d3e4de66a8614d42ce2ce6ec9a8863c86 /bfd
parent3f8416d5e15b58f47c7f7e0ef94f5aadd9fe22f0 (diff)
downloadgdb-6c495350ae7a6db62b04322a88b061d7491677a3.zip
gdb-6c495350ae7a6db62b04322a88b061d7491677a3.tar.gz
gdb-6c495350ae7a6db62b04322a88b061d7491677a3.tar.bz2
* elf32-mips.c (mips_elf_object_p): Unconditionally set
elf_bad_symtab, since sometimes the symbol table is messed up and the last symbol is global. PR 6921.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog4
-rw-r--r--bfd/elf32-mips.c23
2 files changed, 6 insertions, 21 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index f83f58c..615cccd 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,5 +1,9 @@
Wed Jul 5 10:31:47 1995 Ian Lance Taylor <ian@cygnus.com>
+ * elf32-mips.c (mips_elf_object_p): Unconditionally set
+ elf_bad_symtab, since sometimes the symbol table is messed up and
+ the last symbol is global.
+
* ecoff.c (_bfd_ecoff_bfd_is_local_label): New function.
* libecoff.h (_bfd_ecoff_bfd_is_local_label): Declare.
* elf32-mips.c (mips_elf_is_local_label): New static function.
diff --git a/bfd/elf32-mips.c b/bfd/elf32-mips.c
index 0ae1065..66f69dd 100644
--- a/bfd/elf32-mips.c
+++ b/bfd/elf32-mips.c
@@ -1018,27 +1018,8 @@ mips_elf_object_p (abfd)
/* Irix 5 is broken. Object file symbol tables are not always
sorted correctly such that local symbols precede global symbols,
- and the sh_info field in the symbol table is not always right.
- We try to quickly check whether the symbol table is broken for
- this BFD, and, if it is, we set elf_bad_symtab in tdata. */
- if (elf_onesymtab (abfd) != 0)
- {
- Elf_Internal_Shdr *symtab_hdr;
- Elf32_External_Sym esym;
-
- symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
- if (bfd_seek (abfd,
- (symtab_hdr->sh_offset
- + symtab_hdr->sh_size
- - sizeof (Elf32_External_Sym)),
- SEEK_SET) != 0
- || (bfd_read ((PTR) &esym, 1, sizeof (Elf32_External_Sym), abfd)
- != sizeof (Elf32_External_Sym)))
- return false;
- if (ELF_ST_BIND (bfd_h_get_8 (abfd, (bfd_byte *) esym.st_info))
- == STB_LOCAL)
- elf_bad_symtab (abfd) = true;
- }
+ and the sh_info field in the symbol table is not always right. */
+ elf_bad_symtab (abfd) = true;
return true;
}