Simplify iterating over the dynamic section and report broken ones.
[oota-llvm.git] / test / Object / corrupt.test
index 843cc247523f342730f8f7105109afabc6ebf32f..05a8d0fab5c4bfaf921db042329dffdb53747af2 100644 (file)
@@ -50,3 +50,9 @@ RUN:   %p/Inputs/corrupt-invalid-relocation-size.elf.x86-64 2>&1 | \
 RUN:   FileCheck --check-prefix=RELOC %s
 
 RELOC:  Invalid relocation entry size
+
+RUN: not llvm-readobj -dyn-relocations \
+RUN:   %p/Inputs/corrupt-invalid-dynamic-table-size.elf.x86-64 2>&1 | \
+RUN:   FileCheck --check-prefix=DYN-TABLE-SIZE %s
+
+DYN-TABLE-SIZE:  Invalid dynamic table size