summaryrefslogtreecommitdiff
path: root/lib/MC/ELFObjectWriter.cpp
diff options
context:
space:
mode:
authorNick Lewycky <nicholas@mxc.ca>2011-10-07 23:29:53 +0000
committerNick Lewycky <nicholas@mxc.ca>2011-10-07 23:29:53 +0000
commitd2fdb4a28560688be5cbc5b2b0c305ec7207cbd0 (patch)
tree6935daa24ba7746035ee5425d1179dddca710e30 /lib/MC/ELFObjectWriter.cpp
parent4a8d43e9a793324eee49758dc160a4e5d8eaa9a4 (diff)
downloadllvm-d2fdb4a28560688be5cbc5b2b0c305ec7207cbd0.tar.gz
llvm-d2fdb4a28560688be5cbc5b2b0c305ec7207cbd0.tar.bz2
llvm-d2fdb4a28560688be5cbc5b2b0c305ec7207cbd0.tar.xz
Don't emit the symbol table entry for the .symtab_shndx section either.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141440 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/MC/ELFObjectWriter.cpp')
-rw-r--r--lib/MC/ELFObjectWriter.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/MC/ELFObjectWriter.cpp b/lib/MC/ELFObjectWriter.cpp
index bb7adb5769..e0ed86222c 100644
--- a/lib/MC/ELFObjectWriter.cpp
+++ b/lib/MC/ELFObjectWriter.cpp
@@ -302,7 +302,8 @@ void ELFObjectWriter::WriteSymbolTable(MCDataFragment *SymtabF,
if (Section.getType() == ELF::SHT_RELA ||
Section.getType() == ELF::SHT_REL ||
Section.getType() == ELF::SHT_STRTAB ||
- Section.getType() == ELF::SHT_SYMTAB)
+ Section.getType() == ELF::SHT_SYMTAB ||
+ Section.getType() == ELF::SHT_SYMTAB_SHNDX)
continue;
WriteSymbolEntry(SymtabF, ShndxF, 0, ELF::STT_SECTION, 0, 0,
ELF::STV_DEFAULT, SectionIndexMap.lookup(&Section), false);