Handle the lack of a symbol table correctly.
authorStephen Hines <srhines@google.com>
Thu, 26 Jul 2018 20:05:31 +0000 (20:05 +0000)
committerStephen Hines <srhines@google.com>
Thu, 26 Jul 2018 20:05:31 +0000 (20:05 +0000)
commite6e75bf84c94e03313594c1b5faf2b8065969c39
treef5e01740d9cfce74e014d80b868aef5f6c933515
parentd742d645a1fc6630e462c5702c4429368cc41077
Handle the lack of a symbol table correctly.

Summary:
These two cases will trigger a dereference on a nullptr, since the
SymbolTable can be nonexistent for a given library, in addition to just
being empty.

Reviewers: alexshap

Reviewed By: alexshap

Subscribers: meikeb, kongyi, chh, jakehehrlich, llvm-commits, pirama

Differential Revision: https://reviews.llvm.org/D49534

llvm-svn: 338062
llvm/test/tools/llvm-objcopy/strip-all.test
llvm/tools/llvm-objcopy/llvm-objcopy.cpp