From 67704ce493a6b2501ad47a61f73019ac919a2475 Mon Sep 17 00:00:00 2001 From: Michael R Sweet Date: Mon, 21 Apr 2025 16:59:59 -0400 Subject: [PATCH] Update corpus test script to use Xpdf's pdfinfo to weed out known-bad PDFs for now. --- test-corpus.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/test-corpus.sh b/test-corpus.sh index e929b29..ff33086 100755 --- a/test-corpus.sh +++ b/test-corpus.sh @@ -18,5 +18,12 @@ if test $# = 0; then fi for file in $(find "$@" -name \*.pdf -print); do - ./testpdfio $file 2>&1 >$file.log || echo $file + pdfinfo $file >/dev/null 2>&1 || continue; + + ./testpdfio $file >$file.log 2>&1 + if test $? = 0; then + rm -f $file.log + else + echo $file + fi done