From ea71d23f742999c432e26189e9548bff8c8d7294 Mon Sep 17 00:00:00 2001 From: Jonas Jenwald Date: Wed, 5 Jul 2017 19:38:44 +0200 Subject: [PATCH] Fix a stupid spelling error in the `ASCII85Decode` name in `Parser.makeInlineImage` (issue 8613) This is a trivial follow-up to PR 5383, and it's a bit strange that this has been wrong since late 2014 without anyone noticing (maybe because inline images aren't too common). So, apparently code works better if you actually spell correctly, who knew ;-) Fixes 8613. --- src/core/parser.js | 2 +- test/pdfs/issue8613.pdf.link | 1 + test/test_manifest.json | 7 +++++++ 3 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 test/pdfs/issue8613.pdf.link diff --git a/src/core/parser.js b/src/core/parser.js index 3a3c6ce1e..0527815a7 100644 --- a/src/core/parser.js +++ b/src/core/parser.js @@ -373,7 +373,7 @@ var Parser = (function ParserClosure() { var startPos = stream.pos, length, i, ii; if (filterName === 'DCTDecode' || filterName === 'DCT') { length = this.findDCTDecodeInlineStreamEnd(stream); - } else if (filterName === 'ASCII85Decide' || filterName === 'A85') { + } else if (filterName === 'ASCII85Decode' || filterName === 'A85') { length = this.findASCII85DecodeInlineStreamEnd(stream); } else if (filterName === 'ASCIIHexDecode' || filterName === 'AHx') { length = this.findASCIIHexDecodeInlineStreamEnd(stream); diff --git a/test/pdfs/issue8613.pdf.link b/test/pdfs/issue8613.pdf.link new file mode 100644 index 000000000..38a2711c2 --- /dev/null +++ b/test/pdfs/issue8613.pdf.link @@ -0,0 +1 @@ +https://github.com/mozilla/pdf.js/files/1125062/Factuur.9.Schilderwerk.Dr.Stiemensweg.22-24.Dichterbij.pdf diff --git a/test/test_manifest.json b/test/test_manifest.json index bbfed2166..5a4006507 100644 --- a/test/test_manifest.json +++ b/test/test_manifest.json @@ -2945,6 +2945,13 @@ "type": "eq", "about": "Inline image with ASCII85Decode filter." }, + { "id": "issue8613", + "file": "pdfs/issue8613.pdf", + "md5": "bc7ad2db75710aa9916c5769e0c02123", + "rounds": 1, + "link": true, + "type": "eq" + }, { "id": "bug1108753", "file": "pdfs/bug1108753.pdf", "md5": "a7aaf92d55b4602afb0ca3d75198b56b",