summaryrefslogtreecommitdiffstats
path: root/llvm/test/Object
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/test/Object')
-rw-r--r--llvm/test/Object/Inputs/macho64-invalid-too-small-load-command.1bin0 -> 88 bytes
-rw-r--r--llvm/test/Object/macho-invalid.test4
2 files changed, 4 insertions, 0 deletions
diff --git a/llvm/test/Object/Inputs/macho64-invalid-too-small-load-command.1 b/llvm/test/Object/Inputs/macho64-invalid-too-small-load-command.1
new file mode 100644
index 00000000000..cb8886ed3f7
--- /dev/null
+++ b/llvm/test/Object/Inputs/macho64-invalid-too-small-load-command.1
Binary files differ
diff --git a/llvm/test/Object/macho-invalid.test b/llvm/test/Object/macho-invalid.test
index 92b18079b5d..4ddea18fedf 100644
--- a/llvm/test/Object/macho-invalid.test
+++ b/llvm/test/Object/macho-invalid.test
@@ -19,6 +19,10 @@ RUN: not llvm-objdump -macho -private-headers %p/Inputs/macho64-invalid-too-smal
RUN: | FileCheck -check-prefix SMALL-LOADC-SIZE %s
SMALL-LOADC-SIZE: truncated or malformed object (load commands extend past the end of the file)
+RUN: not llvm-objdump -macho -private-headers %p/Inputs/macho64-invalid-too-small-load-command.1 2>&1 \
+RUN: | FileCheck -check-prefix SMALL-LOADC-SIZE-1 %s
+SMALL-LOADC-SIZE-1: truncated or malformed object (load command 1 with size less than 8 bytes)
+
RUN: not llvm-objdump -private-headers %p/Inputs/macho-invalid-too-small-segment-load-command 2>&1 \
RUN: | FileCheck -check-prefix SMALL-SEGLOADC-SIZE %s
RUN: not llvm-objdump -private-headers %p/Inputs/macho64-invalid-too-small-segment-load-command 2>&1 \
OpenPOWER on IntegriCloud