mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-24 20:28:28 +08:00
2010-10-01 Thomas Schwinge <thomas@codesourcery.com>
* elf32-arm.c (elf32_arm_size_stubs): Don't choke on local symbols in SHN_UNDEF, SHN_ABS, SHN_COMMON.
This commit is contained in:
@ -1,3 +1,8 @@
|
|||||||
|
2010-10-01 Thomas Schwinge <thomas@codesourcery.com>
|
||||||
|
|
||||||
|
* elf32-arm.c (elf32_arm_size_stubs): Don't choke on local symbols in
|
||||||
|
SHN_UNDEF, SHN_ABS, SHN_COMMON.
|
||||||
|
|
||||||
2010-09-30 H.J. Lu <hongjiu.lu@intel.com>
|
2010-09-30 H.J. Lu <hongjiu.lu@intel.com>
|
||||||
|
|
||||||
PR ld/11812
|
PR ld/11812
|
||||||
|
@ -4486,7 +4486,6 @@ elf32_arm_size_stubs (bfd *output_bfd,
|
|||||||
{
|
{
|
||||||
/* It's a local symbol. */
|
/* It's a local symbol. */
|
||||||
Elf_Internal_Sym *sym;
|
Elf_Internal_Sym *sym;
|
||||||
Elf_Internal_Shdr *hdr;
|
|
||||||
|
|
||||||
if (local_syms == NULL)
|
if (local_syms == NULL)
|
||||||
{
|
{
|
||||||
@ -4502,8 +4501,16 @@ elf32_arm_size_stubs (bfd *output_bfd,
|
|||||||
}
|
}
|
||||||
|
|
||||||
sym = local_syms + r_indx;
|
sym = local_syms + r_indx;
|
||||||
hdr = elf_elfsections (input_bfd)[sym->st_shndx];
|
if (sym->st_shndx == SHN_UNDEF)
|
||||||
sym_sec = hdr->bfd_section;
|
sym_sec = bfd_und_section_ptr;
|
||||||
|
else if (sym->st_shndx == SHN_ABS)
|
||||||
|
sym_sec = bfd_abs_section_ptr;
|
||||||
|
else if (sym->st_shndx == SHN_COMMON)
|
||||||
|
sym_sec = bfd_com_section_ptr;
|
||||||
|
else
|
||||||
|
sym_sec =
|
||||||
|
bfd_section_from_elf_index (input_bfd, sym->st_shndx);
|
||||||
|
|
||||||
if (!sym_sec)
|
if (!sym_sec)
|
||||||
/* This is an undefined symbol. It can never
|
/* This is an undefined symbol. It can never
|
||||||
be resolved. */
|
be resolved. */
|
||||||
|
Reference in New Issue
Block a user