mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-19 09:14:14 +08:00
Fix a seg-fault when stripping a corrupt binary.
PR 20089 * objcopy.c (group_signature): Fail if the input symbol table has not been loaded.
This commit is contained in:
@ -1125,6 +1125,10 @@ group_signature (asection *group)
|
||||
bfd *abfd = group->owner;
|
||||
Elf_Internal_Shdr *ghdr;
|
||||
|
||||
/* PR 20089: An earlier error may have prevented us from loading the symbol table. */
|
||||
if (isympp == NULL)
|
||||
return NULL;
|
||||
|
||||
if (bfd_get_flavour (abfd) != bfd_target_elf_flavour)
|
||||
return NULL;
|
||||
|
||||
|
Reference in New Issue
Block a user