x86: Check valid PLT sections before checking dynamic relocations
authorH.J. Lu <hjl.tools@gmail.com>
Tue, 29 Aug 2017 17:40:03 +0000 (10:40 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Tue, 29 Aug 2017 17:40:03 +0000 (10:40 -0700)
commit37c0b6ee65941d54fa8064c21b39f97fdc318156
treeb11d475a03364db93860b3ea9a9a267af94fdbbd
parent7ef3addbe195b6283d0baf59e081146dfb211c97
x86: Check valid PLT sections before checking dynamic relocations

Update x86 get_synthetic_symtab to check valid PLT sections before
checking dynamic relocations and free invalid PLT section contents.

* elf32-i386.c (elf_i386_get_synthetic_symtab): Check valid PLT
sections before checking dynamic relocations and free invalid
PLT section contents.
* elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.
bfd/ChangeLog
bfd/elf32-i386.c
bfd/elf64-x86-64.c