mirror of
https://github.com/zebrajr/node.git
synced 2026-01-15 12:15:26 +00:00
set default encoding in sendBody
This commit is contained in:
committed by
Ryan Dahl
parent
6e3d12f617
commit
4e16e386fe
@@ -205,6 +205,7 @@ OutgoingMessage.prototype.sendHeaderLines = function (first_line, headers) {
|
||||
};
|
||||
|
||||
OutgoingMessage.prototype.sendBody = function (chunk, encoding) {
|
||||
encoding = encoding || "ascii";
|
||||
if (this.chunked_encoding) {
|
||||
this.send(process._byteLength(chunk, encoding).toString(16));
|
||||
this.send(CRLF);
|
||||
|
||||
Reference in New Issue
Block a user