mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-19 14:48:08 +02:00
Copied entire buffer for flate stream's snarf function (since decoding looks back)
This commit is contained in:
parent
fe277b8d51
commit
a89bd1d30e
1 changed files with 3 additions and 1 deletions
4
pdf.js
4
pdf.js
|
@ -322,7 +322,9 @@ var FlateStream = (function() {
|
|||
var bufferLength = this.bufferLength;
|
||||
var bufferPos = this.bufferPos;
|
||||
var n = 0;
|
||||
while (bufferPos < bufferLength)
|
||||
// entire front of stream needs to be copied over since flate
|
||||
// looksback when decoding
|
||||
while (0 < bufferLength)
|
||||
dest[n++] = this.buffer[bufferPos++];
|
||||
// now use dest as our buffer and fill it
|
||||
this.buffer = dest;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue