From d3ddee61c2f83e2a3b7ebabfbefee060801d27f5 Mon Sep 17 00:00:00 2001 From: Ben Noordhuis Date: Mon, 29 Apr 2013 14:12:24 +0200 Subject: http: forward-port missing bits from 01e2920 Forward-port the comments from commit 01e2920 (v0.10) to the master branch. Everything else from that patch already exists in master. It didn't merge cleanly because lib/http.js has been split up in several files. --- lib/_http_incoming.js | 3 +++ 1 file changed, 3 insertions(+) (limited to 'lib/_http_incoming.js') diff --git a/lib/_http_incoming.js b/lib/_http_incoming.js index 53a3a386fa..c089ec9e24 100644 --- a/lib/_http_incoming.js +++ b/lib/_http_incoming.js @@ -102,6 +102,9 @@ IncomingMessage.prototype._read = function(n) { }; +// It's possible that the socket will be destroyed, and removed from +// any messages, before ever calling this. In that case, just skip +// it, since something else is destroying this connection anyway. IncomingMessage.prototype.destroy = function(error) { if (this.socket) this.socket.destroy(error); -- cgit v1.2.3