[PATCH] D82935: [llvm-objcopy] Fix crash when removing symbol table at same time as adding a symbol

Georgy Komarov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 2 22:39:13 PDT 2020


jubnzv updated this revision to Diff 275294.
jubnzv added a comment.

> Actually, does the createSymbolTable function even need to be a member of ELFBuilder? My main objection is the use of the builder a long time after initialization of the Object (along with the complexity of calling it due to the template), but I don't think you actually need it.

Yes, I agree, this template call looked clumsily. I wasn't sure which class in the hierarchy should be responsible for symtab creation.
I think we can define a method in the Object itself.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D82935/new/

https://reviews.llvm.org/D82935

Files:
  llvm/test/tools/llvm-objcopy/ELF/add-symbol-new-symtab.test
  llvm/tools/llvm-objcopy/ELF/ELFObjcopy.cpp
  llvm/tools/llvm-objcopy/ELF/Object.cpp
  llvm/tools/llvm-objcopy/ELF/Object.h

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D82935.275294.patch
Type: text/x-patch
Size: 5903 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200703/a7b26804/attachment.bin>


More information about the llvm-commits mailing list