diff options
author | Alexandre Oliva <aoliva@redhat.com> | 2003-01-29 08:29:34 +0000 |
---|---|---|
committer | Alexandre Oliva <aoliva@redhat.com> | 2003-01-29 08:29:34 +0000 |
commit | 38985a1cb4890f44601f781654c6d79485634120 (patch) | |
tree | 48732a1cc038e18d4f90250bbf82abd9ad04eb81 /bfd/elfxx-mips.c | |
parent | 1dc0220c4f346b3cc732bf02de650df703cda48c (diff) | |
download | gdb-38985a1cb4890f44601f781654c6d79485634120.zip gdb-38985a1cb4890f44601f781654c6d79485634120.tar.gz gdb-38985a1cb4890f44601f781654c6d79485634120.tar.bz2 |
* elfxx-mips.c (mips_elf_got_entry_hash): Don't dereference
entry->abfd when it's NULL.
Diffstat (limited to 'bfd/elfxx-mips.c')
-rw-r--r-- | bfd/elfxx-mips.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c index 12d898e..22cc8a2 100644 --- a/bfd/elfxx-mips.c +++ b/bfd/elfxx-mips.c @@ -1584,10 +1584,11 @@ mips_elf_got_entry_hash (entry_) { const struct mips_got_entry *entry = (struct mips_got_entry *)entry_; - return entry->abfd->id + entry->symndx + return entry->symndx + (! entry->abfd ? mips_elf_hash_bfd_vma (entry->d.address) - : entry->symndx >= 0 ? mips_elf_hash_bfd_vma (entry->d.addend) - : entry->d.h->root.root.root.hash); + : entry->abfd->id + + (entry->symndx >= 0 ? mips_elf_hash_bfd_vma (entry->d.addend) + : entry->d.h->root.root.root.hash)); } static int |