Subject: Unhandled exception
Greetings!
I'm evaluating Matrix and found an issue I want to share with you.
I'm developing a library which uses Matrix websockets.
The problem at hand is a built-in keep-alive mechanism which periodically sends a space character over the websocket.
The xmpp server do not like this at all and responds with
and closes the connection.
Even though the connection is closed Matrix tries to send another keep-alive, space, character, which results in a application crash.
Edit: I'm using Matrix SDK 2.1.0.3
I'm evaluating Matrix and found an issue I want to share with you.
I'm developing a library which uses Matrix websockets.
The problem at hand is a built-in keep-alive mechanism which periodically sends a space character over the websocket.
The xmpp server do not like this at all and responds with
- <stream:error xmlns:stream='http://etherx.jabber.org/streams'><xml-not-well-formed xmlns='urn:ietf:params:xml:ns:xmpp-streams'></xml-not-well-formed></stream:error>
Even though the connection is closed Matrix tries to send another keep-alive, space, character, which results in a application crash.
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
at Matrix.Net.WebSocket.Send(Byte[] bData)
at Matrix.XmppStream.SendData(String xml)
at Matrix.XmppStream.Send(String xml)
at Matrix.XmppStream.KeepAliveTick(Object state)
at System.Threading.TimerQueueTimer.CallCallbackInContext(Object state)
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.TimerQueueTimer.CallCallback()
at System.Threading.TimerQueueTimer.Fire()
at System.Threading.TimerQueue.FireNextTimers()
at System.Threading.TimerQueue.AppDomainTimerCallback()
at Matrix.Net.WebSocket.Send(Byte[] bData)
at Matrix.XmppStream.SendData(String xml)
at Matrix.XmppStream.Send(String xml)
at Matrix.XmppStream.KeepAliveTick(Object state)
at System.Threading.TimerQueueTimer.CallCallbackInContext(Object state)
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.TimerQueueTimer.CallCallback()
at System.Threading.TimerQueueTimer.Fire()
at System.Threading.TimerQueue.FireNextTimers()
at System.Threading.TimerQueue.AppDomainTimerCallback()
Edit: I'm using Matrix SDK 2.1.0.3
This post was edited on 2018-03-15, 09:38 by Alex.