mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-04 15:45:25 +02:00
[227320] Fix endless loop in SshTerminalShell
This commit is contained in:
parent
c18cb2eaa9
commit
c75fe00c51
1 changed files with 17 additions and 2 deletions
|
@ -8,6 +8,7 @@
|
|||
* Contributors:
|
||||
* Martin Oberhuber (Wind River) - initial API and implementation
|
||||
* Anna Dushistova (MontaVista) - [170910] Integrate the TM Terminal View with RSE
|
||||
* Martin Oberhuber (Wind River) - [227320] Fix endless loop in SshTerminalShell
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.rse.internal.services.ssh.terminal;
|
||||
|
@ -193,8 +194,22 @@ public class SshTerminalShell extends AbstractTerminalShell {
|
|||
|
||||
public void exit() {
|
||||
if (fChannel != null) {
|
||||
fChannel.disconnect();
|
||||
isActive();
|
||||
try {
|
||||
try {
|
||||
getInputStream().close();
|
||||
} catch (IOException ioe) {
|
||||
/* ignore */
|
||||
}
|
||||
try {
|
||||
getOutputStream().close();
|
||||
} catch (IOException ioe) {
|
||||
/* ignore */
|
||||
}
|
||||
fChannel.disconnect();
|
||||
} finally {
|
||||
fChannel = null;
|
||||
isActive();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue