ensureBuffer can modify this.buffer, so read it after ensureBuffer
This commit is contained in:
parent
e928f18736
commit
3f713de5fe
2
pdf.js
2
pdf.js
@ -671,9 +671,9 @@ var PredictorStream = (function() {
|
|||||||
var predictor = this.stream.getByte();
|
var predictor = this.stream.getByte();
|
||||||
var rawBytes = this.stream.getBytes(rowBytes);
|
var rawBytes = this.stream.getBytes(rowBytes);
|
||||||
|
|
||||||
var buffer = this.buffer;
|
|
||||||
var bufferLength = this.bufferLength;
|
var bufferLength = this.bufferLength;
|
||||||
this.ensureBuffer(bufferLength + pixBytes);
|
this.ensureBuffer(bufferLength + pixBytes);
|
||||||
|
var buffer = this.buffer;
|
||||||
|
|
||||||
var currentRow = buffer.subarray(bufferLength, bufferLength + rowBytes);
|
var currentRow = buffer.subarray(bufferLength, bufferLength + rowBytes);
|
||||||
var prevRow = buffer.subarray(bufferLength - rowBytes, bufferLength);
|
var prevRow = buffer.subarray(bufferLength - rowBytes, bufferLength);
|
||||||
|
Loading…
Reference in New Issue
Block a user