mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-25 09:38:06 +02:00
Handle PI with no value in xml parser
- an XML PI contains a target and optionally some content (see https://en.wikipedia.org/wiki/Processing_Instruction) - the parser expected to always have some content and so it could lead to wrong parsing.
This commit is contained in:
parent
17e9cfcd2a
commit
4544ebf38a
2 changed files with 26 additions and 1 deletions
|
@ -145,6 +145,7 @@ class XMLParserBase {
|
|||
pos < s.length &&
|
||||
!isWhitespace(s, pos) &&
|
||||
s[pos] !== ">" &&
|
||||
s[pos] !== "?" &&
|
||||
s[pos] !== "/"
|
||||
) {
|
||||
++pos;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue