[PATCH] D69304: [llvm-objcopy] - Do not crash on object that has relocations but no symbol table.

George Rimar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 22 05:43:09 PDT 2019


grimar created this revision.
grimar added reviewers: jhenderson, MaskRay, rupprecht, alexshap.
Herald added subscribers: seiya, abrachet, jakehehrlich, arichardson, emaste.
Herald added a reviewer: espindola.

It was revealed by D69260 <https://reviews.llvm.org/D69260>.

Tool crashed when scanned relocations in a object without a symbol table.
This patch teaches it either to handle such objects (when relocations
does not use symbols we do not need a symbol table to procceed)
or to show an appropriate error otherwise.

Depends on D69260 <https://reviews.llvm.org/D69260>.


https://reviews.llvm.org/D69304

Files:
  test/tools/llvm-objcopy/ELF/relocations-no-symtab.test
  tools/llvm-objcopy/ELF/Object.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D69304.226034.patch
Type: text/x-patch
Size: 3529 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20191022/34ec57c7/attachment-0001.bin>


More information about the llvm-commits mailing list