Conversation
- Ensure automatic destruction only happens after both 'end' and 'finish' has been emitted through autoDestroy. - Ensure close() callback is always invoked. - Ensure 'error' is only emitted once.
eb857ea to
f9dfae6
Compare
| } | ||
|
|
||
| Transform.call(this, { autoDestroy: false, ...opts }); | ||
| this._hadError = false; |
There was a problem hiding this comment.
We could keep _hadError for compat if necessary.
|
@nodejs/zlib |
|
It would be good to get another review. I would like to get this into the next v13.x release, if this is ready. |
|
Landed in a940143 |
- Ensure automatic destruction only happens after both 'end' and 'finish' has been emitted through autoDestroy. - Ensure close() callback is always invoked. - Ensure 'error' is only emitted once. PR-URL: #32220 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
|
FYI @BridgeAR |
|
Hey @ronag, this doesn't land cleanly on v13.x, should it be backported? |
- Ensure automatic destruction only happens after both 'end' and 'finish' has been emitted through autoDestroy. - Ensure close() callback is always invoked. - Ensure 'error' is only emitted once. PR-URL: nodejs#32220 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Backport-PR-URL: nodejs#32371
|
It appears that as a result of this PR, const { Inflate } = require('zlib');
new Inflate().close(console.error);Prints nothing in 543c046 and I don't know whether this is expected behavior and/or whether the docs should be clearer (either about when to call |
'end' and 'finish' has been emitted through autoDestroy.
Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passes