diff --git a/src/rpc/transport.ts b/src/rpc/transport.ts index 1835d1d111..cf1ec92682 100644 --- a/src/rpc/transport.ts +++ b/src/rpc/transport.ts @@ -29,6 +29,7 @@ export class Transport { constructor(pipeWrite: NodeJS.WritableStream, pipeRead: NodeJS.ReadableStream) { this._pipeWrite = pipeWrite; pipeRead.on('data', buffer => this._dispatch(buffer)); + pipeRead.on('close', () => process.exit(0)); this.onmessage = undefined; this.onclose = undefined; }