Fix bug preventing startXref to be found for files with a single byte EOL encoding
This commit is contained in:
parent
c036334b6f
commit
6eacb55fc4
1 changed files with 1 additions and 1 deletions
|
@ -182,7 +182,7 @@ readStartXref eolStyle input =
|
||||||
BS.length input - BS.length eofMarker
|
BS.length input - BS.length eofMarker
|
||||||
- if BS.last input == BS.last eofMarker then 0 else eolOffset
|
- if BS.last input == BS.last eofMarker then 0 else eolOffset
|
||||||
startXrefPosition =
|
startXrefPosition =
|
||||||
previous eolLastByte (eofMarkerPosition - eolOffset) input + 1
|
previous eolLastByte (eofMarkerPosition - eolOffset - 1) input + 1
|
||||||
startXrefLength = eofMarkerPosition - eolOffset - startXrefPosition
|
startXrefLength = eofMarkerPosition - eolOffset - startXrefPosition
|
||||||
|
|
||||||
parseDocument :: ByteString -> Either ParseError Document
|
parseDocument :: ByteString -> Either ParseError Document
|
||||||
|
|
Loading…
Reference in a new issue