mirror of
https://github.com/nodejs/node.git
synced 2025-08-15 21:58:48 +02:00
v8: fix missing callback in heap utils destroy
This fixes the v8.getHeapSnapshot() calls not properly being destroyed. Pipeline calls would for example not properly end without the callback being in place. PR-URL: https://github.com/nodejs/node/pull/58846 Reviewed-By: Ethan Arrowood <ethan@arrowood.dev> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Chengzhong Wu <legendecas@gmail.com> Reviewed-By: Shelley Vohr <shelley.vohr@gmail.com>
This commit is contained in:
parent
ab9ef37aa7
commit
c08a1d152b
2 changed files with 13 additions and 1 deletions
|
@ -53,11 +53,12 @@ class HeapSnapshotStream extends Readable {
|
|||
this[kHandle].readStart();
|
||||
}
|
||||
|
||||
_destroy() {
|
||||
_destroy(err, callback) {
|
||||
// Release the references on the handle so that
|
||||
// it can be garbage collected.
|
||||
this[kHandle][owner_symbol] = undefined;
|
||||
this[kHandle] = undefined;
|
||||
callback(err);
|
||||
}
|
||||
|
||||
[kUpdateTimer]() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue