net: omit superfluous 'connect' event
Don't emit a 'connect' event on sockets that are handed off to net.Server 'connection' event listeners. 1. It's superfluous because the connection has already been established at that point. 2. The implementation is arguably wrong because the event is emitted on the same tick of the event loop while the rule of thumb is to always emit it on the next one. This has been tried before in commit f0a440d8 but was reverted again in ede1acc1 because the change was incomplete (at least one test hadn't been updated). Fixes #1047 (again).
parent
bb431531
Please register or sign in to comment