提交 ce5efb2b 编写于 作者: D Daniel Imms

Swallow pty kill exception

We just want to make sure it's killed, ignore the ex

Fixes #54754
上级 bf15f4ca
......@@ -98,7 +98,13 @@ export class TerminalProcess implements ITerminalChildProcess, IDisposable {
clearTimeout(this._closeTimeout);
}
this._closeTimeout = setTimeout(() => {
this._ptyProcess.kill();
// Attempt to kill the pty, it may have already been killed at this
// point but we want to make sure
try {
this._ptyProcess.kill();
} catch (ex) {
// Swallow, the pty has already been killed
}
this._onProcessExit.fire(this._exitCode);
this.dispose();
}, 250);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册