From c04cd6ab48e22ad79379369dd0c91f07ae791258 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Tue, 10 Jan 2017 10:30:12 -0800 Subject: [PATCH] Fix terminal error message on every close Fixes #18368 --- .../parts/terminal/electron-browser/terminalInstance.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 6bfcc2aecef..d97c72fc963 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -373,12 +373,12 @@ export class TerminalInstance implements ITerminalInstance { this._isExiting = true; let exitCodeMessage: string; - if (exitCode !== 0) { + if (exitCode) { exitCodeMessage = nls.localize('terminal.integrated.exitedWithCode', 'The terminal process terminated with exit code: {0}', exitCode); } if (this._shellLaunchConfig.waitOnExit) { - if (exitCode !== 0) { + if (exitCode) { this._xterm.writeln(exitCodeMessage); } this._xterm.writeln(nls.localize('terminal.integrated.waitOnExit', 'Press any key to close the terminal')); @@ -389,7 +389,7 @@ export class TerminalInstance implements ITerminalInstance { }); } else { this.dispose(); - if (exitCode !== 0) { + if (exitCode) { if (this._isLaunching) { let args = ''; if (this._shellLaunchConfig.args && this._shellLaunchConfig.args.length) { -- GitLab