From 1af52d28ca3cc84a5df8dee7236481be0700ef05 Mon Sep 17 00:00:00 2001 From: Micheil Smith Date: Mon, 11 Oct 2010 13:38:57 +1100 Subject: [PATCH] Changing http.js to use the same stream.Stream creation as net.js --- lib/http.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/http.js b/lib/http.js index 20b7b0f30b..fd7e9b68f8 100755 --- a/lib/http.js +++ b/lib/http.js @@ -9,7 +9,7 @@ if (debugLevel & 0x4) { } var net = require('net'); -var Stream = require('stream').Stream; +var stream = require('stream'); var FreeList = require('freelist').FreeList; var HTTPParser = process.binding('http_parser').HTTPParser; @@ -185,7 +185,7 @@ var continueExpression = /100-continue/i; /* Abstract base class for ServerRequest and ClientResponse. */ function IncomingMessage (socket) { - Stream.call(this); + stream.Stream.call(this); // TODO Remove one of these eventually. this.socket = socket; @@ -205,7 +205,7 @@ function IncomingMessage (socket) { this.statusCode = null; this.client = this.socket; } -sys.inherits(IncomingMessage, Stream); +sys.inherits(IncomingMessage, stream.Stream); exports.IncomingMessage = IncomingMessage; IncomingMessage.prototype._parseQueryString = function () { @@ -282,7 +282,7 @@ IncomingMessage.prototype._addHeaderLine = function (field, value) { }; function OutgoingMessage (socket) { - Stream.call(this); + stream.Stream.call(this); // TODO Remove one of these eventually. this.socket = socket; @@ -301,7 +301,7 @@ function OutgoingMessage (socket) { this.finished = false; } -sys.inherits(OutgoingMessage, Stream); +sys.inherits(OutgoingMessage, stream.Stream); exports.OutgoingMessage = OutgoingMessage; // This abstract either writing directly to the socket or buffering it.