diff options
author | Nick Clifton <nickc@redhat.com> | 2025-02-05 16:27:38 +0000 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2025-02-05 16:27:38 +0000 |
commit | b425859021d17adf62f06fb904797cf8642986ad (patch) | |
tree | 33fbd313bd947549a3beb75014355bb3ede4013c | |
parent | 931494c9a89558acb36a03a340c01726545eef24 (diff) | |
download | binutils-master.zip binutils-master.tar.gz binutils-master.tar.bz2 |
PR 32644
-rw-r--r-- | bfd/elflink.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/bfd/elflink.c b/bfd/elflink.c index bf94094..df6eb25 100644 --- a/bfd/elflink.c +++ b/bfd/elflink.c @@ -15116,6 +15116,10 @@ bfd_elf_reloc_symbol_deleted_p (bfd_vma offset, void *cookie) } else { + if (r_symndx >= rcookie->locsymcount) + /* This can happen with corrupt input. */ + return false; + /* It's not a relocation against a global symbol, but it could be a relocation against a local symbol for a discarded section. */ |