lib: jslint string_decoder.js

archived-io.js-v0.10
Fedor Indutny 2014-07-15 12:43:59 +04:00
parent a96d6603b3
commit 9d9fc3fa30
1 changed files with 2 additions and 2 deletions

View File

@ -82,8 +82,8 @@ StringDecoder.prototype.write = function(buffer) {
while (this.charLength) {
// determine how many remaining bytes this buffer has to offer for this char
var available = (buffer.length >= this.charLength - this.charReceived) ?
this.charLength - this.charReceived :
buffer.length;
this.charLength - this.charReceived :
buffer.length;
// add the new bytes to the char buffer
buffer.copy(this.charBuffer, this.charReceived, 0, available);