diff options
author | Daniel Jacobowitz <drow@false.org> | 2003-06-06 02:12:04 +0000 |
---|---|---|
committer | Daniel Jacobowitz <drow@false.org> | 2003-06-06 02:12:04 +0000 |
commit | 90fff0d44fd04fd7dee4550364be8a44d1df29a3 (patch) | |
tree | a91c655a2929d49c8c6caac0561423c26b9207c1 /bfd/elfcode.h | |
parent | 7d773d96dba39b73178c6ea4913cfa8f9a0ee4c5 (diff) | |
download | gdb-90fff0d44fd04fd7dee4550364be8a44d1df29a3.zip gdb-90fff0d44fd04fd7dee4550364be8a44d1df29a3.tar.gz gdb-90fff0d44fd04fd7dee4550364be8a44d1df29a3.tar.bz2 |
* elfcode.h (elf_slurp_reloc_table_from_section): Don't dereference
NULL function pointers.
Diffstat (limited to 'bfd/elfcode.h')
-rw-r--r-- | bfd/elfcode.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bfd/elfcode.h b/bfd/elfcode.h index 55c5b42..0263631 100644 --- a/bfd/elfcode.h +++ b/bfd/elfcode.h @@ -1363,7 +1363,9 @@ elf_slurp_reloc_table_from_section (abfd, asect, rel_hdr, reloc_count, relent->addend = rela.r_addend; - if (entsize == sizeof (Elf_External_Rela)) + if ((entsize == sizeof (Elf_External_Rela) + && ebd->elf_info_to_howto != NULL) + || ebd->elf_info_to_howto_rel == NULL) (*ebd->elf_info_to_howto) (abfd, relent, &rela); else (*ebd->elf_info_to_howto_rel) (abfd, relent, &rela); |