diff options
author | Divy Srivastava <dj.srivastava23@gmail.com> | 2023-12-20 07:55:09 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-12-20 07:55:09 +0530 |
commit | 26cf06ed9f5c0ffa42afff3dbe29533ddcb2fbf7 (patch) | |
tree | cf834709f662c7ce0cdd17813837b45b9fea9e9c /ext/node/polyfills/internal/child_process.ts | |
parent | 5aa27c45f1cae6f0121e0860cd4be329ced887a6 (diff) |
fix(node): child_process kill cancel pending IPC reads (#21647)
Diffstat (limited to 'ext/node/polyfills/internal/child_process.ts')
-rw-r--r-- | ext/node/polyfills/internal/child_process.ts | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/node/polyfills/internal/child_process.ts b/ext/node/polyfills/internal/child_process.ts index 0e93e22d3..39c7633e4 100644 --- a/ext/node/polyfills/internal/child_process.ts +++ b/ext/node/polyfills/internal/child_process.ts @@ -296,6 +296,10 @@ export class ChildProcess extends EventEmitter { throw err; } } + + /* Cancel any pending IPC I/O */ + this.disconnect?.(); + this.killed = true; this.signalCode = denoSignal; return this.killed; |