summaryrefslogtreecommitdiffstats
path: root/llvm/test/Object
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2015-07-20 20:07:50 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2015-07-20 20:07:50 +0000
commit33f250931c081497dd68c70cf5be63f77efe0ffa (patch)
treed13307fd3b152e579ca4aae47a176e4499eeea75 /llvm/test/Object
parent93190c4c0b380373a2e3bbbff3bf81a82e858f80 (diff)
downloadbcm5719-llvm-33f250931c081497dd68c70cf5be63f77efe0ffa.tar.gz
bcm5719-llvm-33f250931c081497dd68c70cf5be63f77efe0ffa.zip
Remove Elf_Rela_Iter and Elf_Rel_Iter.
Use just the pointers and check for invalid relocation sections. llvm-svn: 242700
Diffstat (limited to 'llvm/test/Object')
-rwxr-xr-xllvm/test/Object/Inputs/corrupt-invalid-relocation-size.elf.x86-64bin0 -> 2160 bytes
-rw-r--r--llvm/test/Object/corrupt.test7
2 files changed, 7 insertions, 0 deletions
diff --git a/llvm/test/Object/Inputs/corrupt-invalid-relocation-size.elf.x86-64 b/llvm/test/Object/Inputs/corrupt-invalid-relocation-size.elf.x86-64
new file mode 100755
index 00000000000..2798ab34e17
--- /dev/null
+++ b/llvm/test/Object/Inputs/corrupt-invalid-relocation-size.elf.x86-64
Binary files differ
diff --git a/llvm/test/Object/corrupt.test b/llvm/test/Object/corrupt.test
index 9b3daf7b4cf..843cc247523 100644
--- a/llvm/test/Object/corrupt.test
+++ b/llvm/test/Object/corrupt.test
@@ -43,3 +43,10 @@ RUN: %p/Inputs/corrupt-invalid-virtual-addr.elf.x86-64 2>&1 | \
RUN: FileCheck --check-prefix=VIRTADDR %s
VIRTADDR: Virtual address is not in any segment
+
+
+RUN: not llvm-readobj -dyn-relocations \
+RUN: %p/Inputs/corrupt-invalid-relocation-size.elf.x86-64 2>&1 | \
+RUN: FileCheck --check-prefix=RELOC %s
+
+RELOC: Invalid relocation entry size
OpenPOWER on IntegriCloud