[PATCH] D80568: [llvm-objcopy][ELF] Fix removing a group member section.
Igor Kudrin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri May 29 06:29:20 PDT 2020
ikudrin marked 5 inline comments as done.
ikudrin added inline comments.
================
Comment at: llvm/tools/llvm-objcopy/ELF/Object.cpp:973
+Error GroupSection::removeSectionReferences(
+ bool AllowBrokenLinks, function_ref<bool(const SectionBase *)> ToRemove) {
+ llvm::erase_if(GroupMembers, ToRemove);
----------------
jhenderson wrote:
> What happens if you remove the symbol table itself? I'm slightly concerned that it could leave the sh_link field invalid as presumably `Section::removeSectionReferences` won't be called for the GroupSection.
That is another issue with group sections, but not something which is introduced by this patch. Note that the base class for `GroupSection` is `SectionBase`, not `Section`. We need another patch for that.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D80568/new/
https://reviews.llvm.org/D80568
More information about the llvm-commits
mailing list