mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-27 06:17:47 +08:00
Re: PR28420, ecoff fuzzing failures
sym_ptr_ptr NULL results in segfaults. PR 28420 * ecoff.c (ecoff_slurp_reloc_table): Don't leave sym_ptr_ptr NULL.
This commit is contained in:
@ -1606,7 +1606,7 @@ ecoff_slurp_reloc_table (bfd *abfd,
|
|||||||
(*backend->swap_reloc_in) (abfd,
|
(*backend->swap_reloc_in) (abfd,
|
||||||
external_relocs + i * external_reloc_size,
|
external_relocs + i * external_reloc_size,
|
||||||
&intern);
|
&intern);
|
||||||
rptr->sym_ptr_ptr = NULL;
|
rptr->sym_ptr_ptr = bfd_abs_section_ptr->symbol_ptr_ptr;
|
||||||
rptr->addend = 0;
|
rptr->addend = 0;
|
||||||
|
|
||||||
if (intern.r_extern)
|
if (intern.r_extern)
|
||||||
@ -1617,9 +1617,6 @@ ecoff_slurp_reloc_table (bfd *abfd,
|
|||||||
< (ecoff_data (abfd)->debug_info.symbolic_header.iextMax)))
|
< (ecoff_data (abfd)->debug_info.symbolic_header.iextMax)))
|
||||||
rptr->sym_ptr_ptr = symbols + intern.r_symndx;
|
rptr->sym_ptr_ptr = symbols + intern.r_symndx;
|
||||||
}
|
}
|
||||||
else if (intern.r_symndx == RELOC_SECTION_NONE
|
|
||||||
|| intern.r_symndx == RELOC_SECTION_ABS)
|
|
||||||
rptr->sym_ptr_ptr = bfd_abs_section_ptr->symbol_ptr_ptr;
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
const char *sec_name;
|
const char *sec_name;
|
||||||
|
Reference in New Issue
Block a user