diff --git a/lib/tls.js b/lib/tls.js index 6204a9cb5f8..afca4c63ca7 100644 --- a/lib/tls.js +++ b/lib/tls.js @@ -289,8 +289,9 @@ CryptoStream.prototype._pull = function() { // TODO check if we get EAGAIN From shutdown, would have to do it // again. should unshift END_OF_FILE back onto pending and wait for // next cycle. + + this.pair.encrypted._destroyAfterPush = true; } - this.pair.encrypted._destroyAfterPush = true; this.pair._cycle(); this._done() return;