OSDN Git Service

llvm-objdump: handle stubbed and malformed dylibs better
authorTim Northover <tnorthover@apple.com>
Thu, 14 Jul 2016 22:13:32 +0000 (22:13 +0000)
committerTim Northover <tnorthover@apple.com>
Thu, 14 Jul 2016 22:13:32 +0000 (22:13 +0000)
commit323f7893f4b3f681330f10ecfe8ca7feee16b27d
treee6aaf5095c2d038825fe9631da77a5a1b4eff73b
parent9c524094cf9a7547a3a802cd1ee095b8b52d3eaa
llvm-objdump: handle stubbed and malformed dylibs better

We were quite happy to read past the end of the valid section data when
disassembling. Instead we entirely skip stub dylibs, and tell the user what's
happened if their section only has partial data.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@275487 91177308-0d34-0410-b5e6-96231b3b80d8
test/tools/llvm-objdump/X86/Inputs/stubbed.dylib.macho-x86_64 [new file with mode: 0755]
test/tools/llvm-objdump/X86/Inputs/truncated-section.dylib.macho-x86_64 [new file with mode: 0755]
test/tools/llvm-objdump/X86/stubbed-dylib.test [new file with mode: 0644]
test/tools/llvm-objdump/X86/truncated-section.test [new file with mode: 0644]
tools/llvm-objdump/MachODump.cpp