Merge pull request #5005 from fkaelberer/faster_ChunkedStream_getByte
Faster chunkedStream_getByte()
This commit is contained in:
commit
9c6316fc15
3 changed files with 16 additions and 15 deletions
|
@ -531,12 +531,10 @@ var FlateStream = (function FlateStreamClosure() {
|
|||
this.eof = true;
|
||||
}
|
||||
} else {
|
||||
for (var n = bufferLength; n < end; ++n) {
|
||||
if ((b = str.getByte()) === -1) {
|
||||
this.eof = true;
|
||||
break;
|
||||
}
|
||||
buffer[n] = b;
|
||||
var block = str.getBytes(blockLen);
|
||||
buffer.set(block, bufferLength);
|
||||
if (block.length < blockLen) {
|
||||
this.eof = true;
|
||||
}
|
||||
}
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue