diff --git a/qpdf/qtest/qpdf.test b/qpdf/qtest/qpdf.test index cf73c992..db1c6033 100644 --- a/qpdf/qtest/qpdf.test +++ b/qpdf/qtest/qpdf.test @@ -932,7 +932,7 @@ for (my $n = 16; $n <= 19; ++$n) show_ntests(); # ---------- $td->notify("--- Specific File Tests ---"); -$n_tests += 4; +$n_tests += 5; $n_compare_pdfs += 1; # Special PDF files that caused problems at some point @@ -961,6 +961,10 @@ $td->runtest("damaged stream", {$td->COMMAND => "qpdf --check damaged-stream.pdf"}, {$td->FILE => "damaged-stream.out", $td->EXIT_STATUS => 3}, $td->NORMALIZE_NEWLINES); +$td->runtest("damaged stream (C)", + {$td->COMMAND => "qpdf-ctest 2 damaged-stream.pdf '' a.pdf"}, + {$td->FILE => "damaged-stream-c-check.out", $td->EXIT_STATUS => 0}, + $td->NORMALIZE_NEWLINES); show_ntests(); # ---------- diff --git a/qpdf/qtest/qpdf/damaged-stream-c-check.out b/qpdf/qtest/qpdf/damaged-stream-c-check.out index b1723623..501806d2 100644 --- a/qpdf/qtest/qpdf/damaged-stream-c-check.out +++ b/qpdf/qtest/qpdf/damaged-stream-c-check.out @@ -1 +1,5 @@ -warning: damaged-stream.pdf: offset 426: error decoding stream data for object 5 0: LZWDecoder: bad code received +warning: damaged-stream.pdf (file position 426): error decoding stream data for object 5 0: LZWDecoder: bad code received + code: 5 + file: damaged-stream.pdf + pos : 426 + text: error decoding stream data for object 5 0: LZWDecoder: bad code received