Skip to content

Commit 4250ba0

Browse files
committed
Add quick-and-dirty logging for OnMessage exceptions
1 parent 33f50d1 commit 4250ba0

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Signal-Windows.Lib/IncomingMessages.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,14 @@ public async Task OnMessage(SignalServiceMessagePipeMessage message)
9494
SignalLibHandle.Instance.DispatchPipeEmptyMessage();
9595
}
9696
}
97+
catch (Exception e)
98+
{
99+
Logger.LogError("OnMessage failed: {0}\n{1}", e.Message, e.StackTrace);
100+
if (e.InnerException != null)
101+
{
102+
Logger.LogError("InnerException: {0}\n{1}", e.InnerException.Message, e.InnerException.StackTrace);
103+
}
104+
}
97105
finally
98106
{
99107
SignalLibHandle.Instance.SemaphoreSlim.Release();

0 commit comments

Comments
 (0)