From 98073c826b6eb1b78f8dc695577d09d4ee9cf6b8 Mon Sep 17 00:00:00 2001 From: Lei Zhang Date: Mon, 31 Jul 2017 19:33:25 -0700 Subject: Add a regression test for FPDF_ImportPages(). BUG=chromium:750558 Change-Id: I0d541c660c529b368f420d461a6eb1d81e42579a Reviewed-on: https://pdfium-review.googlesource.com/9730 Reviewed-by: Ryan Harrison Commit-Queue: Lei Zhang --- testing/resources/bug_750568.in | 77 ++++++++++++++++++++++++++++++++++ testing/resources/bug_750568.pdf | 91 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 168 insertions(+) create mode 100644 testing/resources/bug_750568.in create mode 100644 testing/resources/bug_750568.pdf (limited to 'testing') diff --git a/testing/resources/bug_750568.in b/testing/resources/bug_750568.in new file mode 100644 index 0000000000..9d72093827 --- /dev/null +++ b/testing/resources/bug_750568.in @@ -0,0 +1,77 @@ +{{header}} +{{object 1 0}} << + /Type /Catalog + /Pages 2 0 R +>> +endobj +{{object 2 0}} << + /Type /Pages + /MediaBox [ 0 0 200 200 ] + /Count 4 + /Kids [ 3 0 R 4 0 R 5 0 R 6 0 R ] +>> +endobj +{{object 3 0}} << + /Type /Page + /Parent 2 0 R + /Contents 7 0 R +>> +endobj +{{object 4 0}} << + /Type /Page + /Parent 2 0 R + /Contents 8 0 R +>> +endobj +{{object 5 0}} << + /Type /Page + /Parent 2 0 R + /Contents 9 0 R +>> +endobj +{{object 6 0}} << + /Type /Page + /Parent 2 0 R + /Contents 10 0 R +>> +endobj +{{object 7 0}} << +>> +stream +q +0 0 0 rg +10 80 50 30 re B* +Q +endstream +endobj +{{object 8 0}} << +>> +stream +q +0 0 1 rg +70 135 50 30 re B* +Q +endstream +endobj +{{object 9 0}} << +>> +stream +q +0 1 0 rg +130 80 50 30 re B* +Q +endstream +endobj +{{object 10 0}} << +>> +stream +q +1 0 0 rg +70 25 50 30 re B* +Q +endstream +endobj +{{xref}} +{{trailer}} +{{startxref}} +%%EOF diff --git a/testing/resources/bug_750568.pdf b/testing/resources/bug_750568.pdf new file mode 100644 index 0000000000..5fb60142bd --- /dev/null +++ b/testing/resources/bug_750568.pdf @@ -0,0 +1,91 @@ +%PDF-1.7 +% ò¤ô +1 0 obj << + /Type /Catalog + /Pages 2 0 R +>> +endobj +2 0 obj << + /Type /Pages + /MediaBox [ 0 0 200 200 ] + /Count 4 + /Kids [ 3 0 R 4 0 R 5 0 R 6 0 R ] +>> +endobj +3 0 obj << + /Type /Page + /Parent 2 0 R + /Contents 7 0 R +>> +endobj +4 0 obj << + /Type /Page + /Parent 2 0 R + /Contents 8 0 R +>> +endobj +5 0 obj << + /Type /Page + /Parent 2 0 R + /Contents 9 0 R +>> +endobj +6 0 obj << + /Type /Page + /Parent 2 0 R + /Contents 10 0 R +>> +endobj +7 0 obj << +>> +stream +q +0 0 0 rg +10 80 50 30 re B* +Q +endstream +endobj +8 0 obj << +>> +stream +q +0 0 1 rg +70 135 50 30 re B* +Q +endstream +endobj +9 0 obj << +>> +stream +q +0 1 0 rg +130 80 50 30 re B* +Q +endstream +endobj +10 0 obj << +>> +stream +q +1 0 0 rg +70 25 50 30 re B* +Q +endstream +endobj +xref +0 11 +0000000000 65535 f +0000000015 00000 n +0000000068 00000 n +0000000179 00000 n +0000000248 00000 n +0000000317 00000 n +0000000386 00000 n +0000000456 00000 n +0000000525 00000 n +0000000595 00000 n +0000000665 00000 n +trailer<< /Root 1 0 R /Size 11 >> +startxref +735 +%%EOF -- cgit v1.2.3