mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-21 07:38:07 +02:00
Consume the current character when encountering illegal characters in Lexer.getObject
, in order to prevent infinite loops during reading of streams (issue 8061)
*Please note:* The rendering of the PDF file in issue 8061 first regressed in PR 7039, and then PR 7493 exacerbated the problem even further by causing an infinite loop. In this particular case, when errors were encountered inside of the `Lexer.getObject` method *itself*, we didn't advance the stream position. This thus caused an inifinite loop in `parseCMap`, since the exact same character was then parsed over and over again. Fixes 8061.
This commit is contained in:
parent
da08b801a5
commit
23c62cc321
4 changed files with 13 additions and 0 deletions
1
test/pdfs/.gitignore
vendored
1
test/pdfs/.gitignore
vendored
|
@ -45,6 +45,7 @@
|
|||
!issue7855.pdf
|
||||
!issue7872.pdf
|
||||
!issue7901.pdf
|
||||
!issue8061.pdf
|
||||
!bad-PageLabels.pdf
|
||||
!filled-background.pdf
|
||||
!ArabicCIDTrueType.pdf
|
||||
|
|
BIN
test/pdfs/issue8061.pdf
Normal file
BIN
test/pdfs/issue8061.pdf
Normal file
Binary file not shown.
|
@ -1712,6 +1712,13 @@
|
|||
"link": false,
|
||||
"type": "eq"
|
||||
},
|
||||
{ "id": "issue8061",
|
||||
"file": "pdfs/issue8061.pdf",
|
||||
"md5": "d61fe1dcdcd55bca00b351b2fc2c6dc7",
|
||||
"rounds": 1,
|
||||
"link": false,
|
||||
"type": "eq"
|
||||
},
|
||||
{ "id": "issue7580-eq",
|
||||
"file": "pdfs/issue7580.pdf",
|
||||
"md5": "44dd5a9b4373fcab9890cf567722a766",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue