872
/** Record the command's exit on an output-only terminal and notify subscribers. */
873
finalizeOutputTerminal(uri: string, exitCode: number | undefined): void {
875
>
if (!terminal || terminal.exitCode !== undefined) {
876
>
return;
877
>
}
878
>
if (exitCode !== undefined) {
879
>
terminal.exitCode = exitCode;
880
>
this._stateManager.dispatchServerAction(uri, {
881
>
type: ActionType.TerminalExited,
882
>
exitCode,
883
>
});
884
>
}
885
>
}
886
887
/** Dispose a terminal: kill the process and remove it. */