Hello,
i am having the following issue on the newest beta version of Renci.SSHNet 2014.4.6.0
If I try to open a ShellStream on a previously opened SSH Session to an embedded Linux system I am getting the following error:
```
SshNet.Logging Verbose: 1 : SendMessage to server 'ChannelDataMessage': 'SSH_MSG_CHANNEL_DATA : #0'.
SshNet.Logging Verbose: 1 : ReceiveMessage from server: 'ChannelDataMessage': 'SSH_MSG_CHANNEL_DATA : #0'.
SshNet.Logging Verbose: 1 : SendMessage to server 'ChannelDataMessage': 'SSH_MSG_CHANNEL_DATA : #0'.
SshNet.Logging Verbose: 1 : ReceiveMessage from server: 'ChannelDataMessage': 'SSH_MSG_CHANNEL_DATA : #0'.
"TIM LiveLogger.vshost.exe" (CLR v4.0.30319: TIM LiveLogger.vshost.exe): "C:\Windows\Microsoft.Net\assembly\GAC_MSIL\mscorlib.resources\v4.0_4.0.0.0_de_b77a5c561934e089\mscorlib.resources.dll" geladen. Das Modul wurde ohne Symbole erstellt.
Eine Ausnahme (erste Chance) des Typs "System.NullReferenceException" ist in XXXXXXX.exe aufgetreten.
```
I created the session from the main thread by a click on a Windows Forms Button:
```
this.ssh_session = new SshClient(this.host, this.port, this.user, this.password);
this.ssh_session.Connect();
this.shell = ssh_session.CreateShellStream("TEST", 0, 0, 0, 0, 0);
this.shell.DataReceived += new EventHandler<Renci.SshNet.Common.ShellDataEventArgs> his.shell_DataReceived);
this.shell.ErrorOccurred += new EventHandler<Renci.SshNet.Common.ExceptionEventArgs>(this.shell_ErrorOccurred);
```
Comments: ** Comment from web user: drieseng **
i am having the following issue on the newest beta version of Renci.SSHNet 2014.4.6.0
If I try to open a ShellStream on a previously opened SSH Session to an embedded Linux system I am getting the following error:
```
SshNet.Logging Verbose: 1 : SendMessage to server 'ChannelDataMessage': 'SSH_MSG_CHANNEL_DATA : #0'.
SshNet.Logging Verbose: 1 : ReceiveMessage from server: 'ChannelDataMessage': 'SSH_MSG_CHANNEL_DATA : #0'.
SshNet.Logging Verbose: 1 : SendMessage to server 'ChannelDataMessage': 'SSH_MSG_CHANNEL_DATA : #0'.
SshNet.Logging Verbose: 1 : ReceiveMessage from server: 'ChannelDataMessage': 'SSH_MSG_CHANNEL_DATA : #0'.
"TIM LiveLogger.vshost.exe" (CLR v4.0.30319: TIM LiveLogger.vshost.exe): "C:\Windows\Microsoft.Net\assembly\GAC_MSIL\mscorlib.resources\v4.0_4.0.0.0_de_b77a5c561934e089\mscorlib.resources.dll" geladen. Das Modul wurde ohne Symbole erstellt.
Eine Ausnahme (erste Chance) des Typs "System.NullReferenceException" ist in XXXXXXX.exe aufgetreten.
```
I created the session from the main thread by a click on a Windows Forms Button:
```
this.ssh_session = new SshClient(this.host, this.port, this.user, this.password);
this.ssh_session.Connect();
this.shell = ssh_session.CreateShellStream("TEST", 0, 0, 0, 0, 0);
this.shell.DataReceived += new EventHandler<Renci.SshNet.Common.ShellDataEventArgs> his.shell_DataReceived);
this.shell.ErrorOccurred += new EventHandler<Renci.SshNet.Common.ExceptionEventArgs>(this.shell_ErrorOccurred);
```
Comments: ** Comment from web user: drieseng **
Eventhandlers are invoked synchronously, and as such they can affect the event publisher.
We could start wrapping each invocation of these delegates in a try/catch, but I don't think we'll be changing our behavior here.