You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At some point remote side disconnects (no logout), which results in SocketException (SocketError.ConnectionReset)
This results in SocketInitiatorThread.Disconnect() method being called
Unfortunately the Session itself is not being touched
The result is that Session is in incorrect state => Session.IsLoggedOn will still return true and Session.Application is not aware of the session going down)
A small change in SocketInitiatorThread.Read() method's exception handling would fix the issue, it will reset the session and call Application.OnLogout():
public bool Read()
{
try
{
int bytesRead = ReadSome(_readBuffer, 1000);
if (bytesRead > 0)
_parser.AddToStream(_readBuffer, bytesRead);
else
Session.Next();
ProcessStream();
return true;
}
catch (ObjectDisposedException)
{
// this exception means _socket is already closed when poll() is called
if (_isDisconnectRequested == false)
Disconnect();
}
catch (Exception e)
{
Session.Log.OnEvent(e.ToString());
if (!Session.HasResponder) // This is a new line
Disconnect();
Session.Disconnect(e.Message); // This is also a new line
}
return false;
}
The text was updated successfully, but these errors were encountered:
Hi,
We have notice following issue:
A small change in SocketInitiatorThread.Read() method's exception handling would fix the issue, it will reset the session and call Application.OnLogout():
The text was updated successfully, but these errors were encountered: