Skip to content

Commit bd0f965

Browse files
committed
net: call resume in internalConnnect
1 parent 07b336d commit bd0f965

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/net.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1033,6 +1033,8 @@ function internalConnect(
10331033
self, address, port, addressType, localAddress, localPort, flags) {
10341034
// TODO return promise from Socket.prototype.connect which
10351035
// wraps _connectReq.
1036+
debug("resume")
1037+
self.resume();
10361038

10371039
assert(self.connecting);
10381040

@@ -1582,7 +1584,7 @@ function afterConnect(status, handle, req, readable, writable) {
15821584

15831585
// Start the first read, or get an immediate EOF.
15841586
// this doesn't actually consume any bytes, because len=0.
1585-
if (readable) {
1587+
if (readable && !self.isPaused()) {
15861588
self.read(0);
15871589
}
15881590

0 commit comments

Comments
 (0)