Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Emit disconnected event instead of error when ECONNRESET
ECONNRESET means the other side of the TCP conversation abruptly closed its end of the connection. If we get an ECONNRESET error from the proxy request and the socket is destroyed this means that the client has closed his connection, and emit this as an error can lead to confusion and hacks to filter that kind of message. I think that the best we can do is abort and emit another event, so if any caller wants to handle with that kind of error, he can by listen the disconnected event. http-party#813
- Loading branch information