[PATCH] D59649: [ELF] Improve error message for relocations to symbols defined in discarded sections
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed May 22 04:35:05 PDT 2019
MaskRay marked an inline comment as done.
MaskRay added inline comments.
================
Comment at: lld/trunk/ELF/Relocations.cpp:688
+
+ Elf_Shdr_Impl<ELFT> ELFSec = ObjSections[Sym.DiscardedSecIdx - 1];
+ if (ELFSec.sh_type != SHT_GROUP)
----------------
We may improve the search for SHT_GROUP. Probably some validation is required. `Sym.DiscardedSecIdx - 1` may not find the belonged SHT_GROUP...
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D59649/new/
https://reviews.llvm.org/D59649
More information about the llvm-commits
mailing list