joyent/node — pull request #4427 by shigeki (2012-12-18 02:10:29+00:00)
Title: stream2: fix to emit end event on http.ClientResponse

An end event on http.ClientResponse is not emitted in stream2 because only `res.resume()` is performed after readable event. ' test-stream2-httpclient-response-end.js' fails due to timeout.
It seems to be necessary to execute `stream._readableState.onread(null, null)` explicitly again like `http.clientResponse._emitEnd()` in `parserOnMessageComplete`.
I wonder if it is the right fix for stream2 but the test of works fine.