Backport a fix for binutils PR7093, which caused segfaults in ld

targeting arm, when attempting to create object files from arbitrary
binary file (e.g. firmware blobs).
This commit is contained in:
Dimitry Andric 2010-11-03 16:46:05 +00:00
parent 964cec1081
commit 8aa660204b

View File

@ -3280,6 +3280,9 @@ bfd_elf32_arm_init_maps (bfd *abfd)
Elf_Internal_Shdr *hdr;
unsigned int i, localsyms;
if (bfd_get_flavour (abfd) != bfd_target_elf_flavour || elf_tdata (abfd) == NULL)
return;
if ((abfd->flags & DYNAMIC) != 0)
return;