Fix an assertion failure when parsing a fuzzed x86_64 ELF binary.
PR 22172 * elf64-x86-64.c (elf_x86_64_info_to_howto): Do not trigger an assertion failure if elf_x86_64_rtype_to_howto has already issued an error message.
This commit is contained in:
parent
00956d3a8a
commit
262c0a877f
|
@ -1,3 +1,10 @@
|
|||
2017-09-26 Nick Clifton <nickc@redhat.com>
|
||||
|
||||
PR 22172
|
||||
* elf64-x86-64.c (elf_x86_64_info_to_howto): Do not trigger an
|
||||
assertion failure if elf_x86_64_rtype_to_howto has already issued
|
||||
an error message.
|
||||
|
||||
2017-09-26 Alan Modra <amodra@gmail.com>
|
||||
|
||||
PR 22210
|
||||
|
|
|
@ -344,7 +344,8 @@ elf_x86_64_info_to_howto (bfd *abfd ATTRIBUTE_UNUSED, arelent *cache_ptr,
|
|||
&& r_type != (unsigned int) R_X86_64_GNU_VTENTRY)
|
||||
r_type &= ~R_X86_64_converted_reloc_bit;
|
||||
cache_ptr->howto = elf_x86_64_rtype_to_howto (abfd, r_type);
|
||||
BFD_ASSERT (r_type == cache_ptr->howto->type);
|
||||
|
||||
BFD_ASSERT (r_type == cache_ptr->howto->type || cache_ptr->howto->type == R_X86_64_NONE);
|
||||
}
|
||||
|
||||
/* Support for core dump NOTE sections. */
|
||||
|
|
Loading…
Reference in New Issue