mirror of
https://github.com/zebrajr/node.git
synced 2026-01-15 12:15:26 +00:00
Fix test-http-buffer-sanity
This commit is contained in:
@@ -322,7 +322,7 @@ OutgoingMessage.prototype._send = function (data, encoding) {
|
||||
}
|
||||
this._headerSent = true;
|
||||
}
|
||||
this._writeRaw(data, encoding);
|
||||
return this._writeRaw(data, encoding);
|
||||
};
|
||||
|
||||
OutgoingMessage.prototype._writeRaw = function(data, encoding) {
|
||||
@@ -347,7 +347,6 @@ OutgoingMessage.prototype._writeRaw = function(data, encoding) {
|
||||
};
|
||||
|
||||
OutgoingMessage.prototype._buffer = function (data, encoding) {
|
||||
// Buffer
|
||||
if (data.length === 0) return;
|
||||
|
||||
var length = this.output.length;
|
||||
|
||||
@@ -665,7 +665,8 @@ Stream.prototype.write = function (data, encoding, fd) {
|
||||
}
|
||||
|
||||
if (typeof data == 'string' &&
|
||||
this._writeQueueEncoding.length &&
|
||||
this._writeQueue.length &&
|
||||
typeof this._writeQueue[this._writeQueue.length-1] === 'string' &&
|
||||
this._writeQueueEncoding[this._writeQueueEncoding.length-1] === encoding) {
|
||||
// optimization - concat onto last
|
||||
this._writeQueue[this._writeQueue.length-1] += data;
|
||||
|
||||
Reference in New Issue
Block a user