Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | [llvm-objcopy] --add-symbol: address post-commit reviews of D69093 | Fangrui Song | 2019-10-31 | 1 | -18/+44 |
| | | | | | | | | | | * Improve comments. * Reorder the assignment to Obj.SectionNames before the symbol table creation code. Add a test. Reviewed By: grimar Differential Revision: https://reviews.llvm.org/D69526 | ||||
* | [llvm-objcopy] --add-symbol: fix crash if SHT_SYMTAB does not exist | Fangrui Song | 2019-10-17 | 1 | -0/+81 |
Exposed by D69041. If SHT_SYMTAB does not exist, ELFObjcopy.cpp:handleArgs will crash due to a null pointer dereference. for (const NewSymbolInfo &SI : Config.ELF->SymbolsToAdd) { ... Obj.SymbolTable->addSymbol( Fix this by creating .symtab and .strtab on demand in ELFBuilder<ELFT>::readSections, if --add-symbol is specified. Reviewed By: grimar Differential Revision: https://reviews.llvm.org/D69093 llvm-svn: 375105 |