diff options
| author | Claus Vium <cvium@users.noreply.github.com> | 2020-09-03 14:54:00 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-09-03 14:54:00 +0200 |
| commit | 2f9b4825550c97d1432033958d7a016d8775dff9 (patch) | |
| tree | 0b896551a3f0d955122190ff6217e6bbd4e16dda /Emby.Server.Implementations/HttpServer/WebSocketConnection.cs | |
| parent | c7b5bc55a1ac985c46b918e4b6208ea1f4ae0b2f (diff) | |
| parent | 8c28824c8878e409ca426e4860dc3f05521f39b8 (diff) | |
Merge branch 'master' into master
Diffstat (limited to 'Emby.Server.Implementations/HttpServer/WebSocketConnection.cs')
| -rw-r--r-- | Emby.Server.Implementations/HttpServer/WebSocketConnection.cs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Emby.Server.Implementations/HttpServer/WebSocketConnection.cs b/Emby.Server.Implementations/HttpServer/WebSocketConnection.cs index d738047e0..7eae4e764 100644 --- a/Emby.Server.Implementations/HttpServer/WebSocketConnection.cs +++ b/Emby.Server.Implementations/HttpServer/WebSocketConnection.cs @@ -179,7 +179,7 @@ namespace Emby.Server.Implementations.HttpServer return; } - WebSocketMessage<object> stub; + WebSocketMessage<object>? stub; try { @@ -209,6 +209,12 @@ namespace Emby.Server.Implementations.HttpServer return; } + if (stub == null) + { + _logger.LogError("Error processing web socket message"); + return; + } + // Tell the PipeReader how much of the buffer we have consumed reader.AdvanceTo(buffer.End); |
