summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/tls.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/tls.js b/lib/tls.js
index fe94a5121f..dcdd99a193 100644
--- a/lib/tls.js
+++ b/lib/tls.js
@@ -1400,7 +1400,7 @@ function pipe(pair, socket) {
// Encrypted should be unpiped from socket to prevent possible
// write after destroy.
pair.encrypted.unpipe(socket);
- socket.destroy();
+ socket.destroySoon();
});
});