|
|
@ -771,8 +771,6 @@ function ServerResponse(req) { |
|
|
|
this.useChunkedEncodingByDefault = false; |
|
|
|
this.shouldKeepAlive = false; |
|
|
|
} |
|
|
|
|
|
|
|
this._httpVersion = req.httpVersion; |
|
|
|
} |
|
|
|
util.inherits(ServerResponse, OutgoingMessage); |
|
|
|
|
|
|
@ -833,9 +831,8 @@ ServerResponse.prototype.writeHead = function(statusCode) { |
|
|
|
headers = obj; |
|
|
|
} |
|
|
|
|
|
|
|
var statusLine = 'HTTP/' + this._httpVersion |
|
|
|
+ ' ' + statusCode.toString() |
|
|
|
+ ' ' + reasonPhrase + CRLF; |
|
|
|
var statusLine = 'HTTP/1.1 ' + statusCode.toString() + ' ' + |
|
|
|
reasonPhrase + CRLF; |
|
|
|
|
|
|
|
if (statusCode === 204 || statusCode === 304 || |
|
|
|
(100 <= statusCode && statusCode <= 199)) { |
|
|
|