tls_wrap: Unlink TLSWrap and SecureContext objects
This makes `TLSWrap` and `SecureContext` objects collectable by the incremental gc. `res = null` destroys the cyclic reference in the `reading` property. `this.ssl = null` removes the remaining reference to the `TLSWrap`. `this.ssl._secureContext.context = null` removes the reference to the `SecureContext` object, even though there might be references to `this.ssl._secureContext` somewhere. The `reading` property will now throw an error if accessed after the socket is closed, but that should not happen. PR-URL: https://github.com/iojs/io.js/pull/1580 Reviewed-By:Fedor Indutny <fedor@indutny.com> Reviewed-By:
Shigeki Ohtsu <ohtsu@iij.ad.jp>
parent
dacc1fa3
Please register or sign in to comment