1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 19:23:23 +01:00
llvm-mirror/tools/llvm-objdump
Kevin Enderby 8be76b0f42 Clean up the specific error message for a malformed Mach-O files with bad segment
load commands.

The existing test case in test/Object/macho-invalid.test for
macho-invalid-too-small-segment-load-command has a cmdsize of 55, while
being too small also it is not a multiple of 4.  So when that check is added
this test case will produce a different error. So I constructed a new test case
that will trigger the intended error.

I also changed the error message to be consistent with the other malformed Mach-O
file error messages which prints the load command index.  I also removed both
object_error::macho_load_segment_too_small and
object_error::macho_load_segment_too_many_sections from Object/Error.h
as they are not needed and can just use object_error::parse_failed and let the
error message string distinguish the specific error.

llvm-svn: 268652
2016-05-05 17:43:35 +00:00
..
CMakeLists.txt Stop linking all target libraries in llvm-nm and llvm-objdump. 2015-10-07 22:39:17 +00:00
COFFDump.cpp Thread Expected<...> up from libObject’s getType() for symbols to allow llvm-objdump to produce a good error message. 2016-05-02 20:28:12 +00:00
ELFDump.cpp Simplify iterating over program headers and detect corrupt ones. 2015-07-20 13:35:33 +00:00
llvm-objdump.cpp Clean up the specific error message for a malformed Mach-O files with bad segment 2016-05-05 17:43:35 +00:00
llvm-objdump.h [NFC] Header cleanup 2016-04-18 09:17:29 +00:00
LLVMBuild.txt
MachODump.cpp Thread Expected<...> up from libObject’s getType() for symbols to allow llvm-objdump to produce a good error message. 2016-05-02 20:28:12 +00:00