aboutsummaryrefslogtreecommitdiff
path: root/bfd/elfxx-mips.c
diff options
context:
space:
mode:
authorThiemo Seufer <ths@networkno.de>2006-07-25 09:06:05 +0000
committerThiemo Seufer <ths@networkno.de>2006-07-25 09:06:05 +0000
commitc000e2621b35acc091086e4d0185453011cb7adb (patch)
tree2e77ea87588d3a8824c9361bcf5684d6a47838cc /bfd/elfxx-mips.c
parent37caec6ba84861ea60063da70e9334c9bd68fb0a (diff)
downloadgdb-c000e2621b35acc091086e4d0185453011cb7adb.zip
gdb-c000e2621b35acc091086e4d0185453011cb7adb.tar.gz
gdb-c000e2621b35acc091086e4d0185453011cb7adb.tar.bz2
* elfxx-mips.c (mips_elf_next_relocation): Tighten check to test
also for same symbol.
Diffstat (limited to 'bfd/elfxx-mips.c')
-rw-r--r--bfd/elfxx-mips.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
index f917ba5..5a65d42 100644
--- a/bfd/elfxx-mips.c
+++ b/bfd/elfxx-mips.c
@@ -3583,9 +3583,12 @@ mips_elf_next_relocation (bfd *abfd ATTRIBUTE_UNUSED, unsigned int r_type,
const Elf_Internal_Rela *relocation,
const Elf_Internal_Rela *relend)
{
+ unsigned long r_symndx = ELF_R_SYM (abfd, relocation->r_info);
+
while (relocation < relend)
{
- if (ELF_R_TYPE (abfd, relocation->r_info) == r_type)
+ if (ELF_R_TYPE (abfd, relocation->r_info) == r_type
+ && ELF_R_SYM (abfd, relocation->r_info) == r_symndx)
return relocation;
++relocation;