mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-20 06:35:50 +02:00
Protect ssh against trivial NPE on shell exit
This commit is contained in:
parent
1785f3e5fb
commit
35d12956f2
1 changed files with 6 additions and 2 deletions
|
@ -168,8 +168,12 @@ public class SshHostShell extends AbstractHostShell implements IHostShell {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void exit() {
|
public void exit() {
|
||||||
fShellWriter.stopThread();
|
if (fShellWriter!=null) {
|
||||||
fChannel.disconnect();
|
fShellWriter.stopThread();
|
||||||
|
}
|
||||||
|
if (fChannel!=null) {
|
||||||
|
fChannel.disconnect();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue