aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/HttpServer/WebSocketConnection.cs
diff options
context:
space:
mode:
authorcrobibero <cody@robibe.ro>2020-08-18 20:20:32 -0600
committercrobibero <cody@robibe.ro>2020-08-18 20:20:32 -0600
commitb43a8fb9d35846f458212d0ad17f3d52c896ef6e (patch)
tree339a40a3e2f2ee73a0ed73cef66fd4bc7c553fb9 /Emby.Server.Implementations/HttpServer/WebSocketConnection.cs
parent2b5d515de79f2309219459c7223b8a56269737f8 (diff)
parent93fe595e5e9863874c1973e4f2d7f3c85549d3f9 (diff)
Merge remote-tracking branch 'upstream/master' into package-install-repo
Diffstat (limited to 'Emby.Server.Implementations/HttpServer/WebSocketConnection.cs')
-rw-r--r--Emby.Server.Implementations/HttpServer/WebSocketConnection.cs8
1 files changed, 4 insertions, 4 deletions
diff --git a/Emby.Server.Implementations/HttpServer/WebSocketConnection.cs b/Emby.Server.Implementations/HttpServer/WebSocketConnection.cs
index 316cd84cf..d738047e0 100644
--- a/Emby.Server.Implementations/HttpServer/WebSocketConnection.cs
+++ b/Emby.Server.Implementations/HttpServer/WebSocketConnection.cs
@@ -19,7 +19,7 @@ namespace Emby.Server.Implementations.HttpServer
/// <summary>
/// Class WebSocketConnection.
/// </summary>
- public class WebSocketConnection : IWebSocketConnection
+ public class WebSocketConnection : IWebSocketConnection, IDisposable
{
/// <summary>
/// The logger.
@@ -119,7 +119,7 @@ namespace Emby.Server.Implementations.HttpServer
Memory<byte> memory = writer.GetMemory(512);
try
{
- receiveresult = await _socket.ReceiveAsync(memory, cancellationToken);
+ receiveresult = await _socket.ReceiveAsync(memory, cancellationToken).ConfigureAwait(false);
}
catch (WebSocketException ex)
{
@@ -137,7 +137,7 @@ namespace Emby.Server.Implementations.HttpServer
writer.Advance(bytesRead);
// Make the data available to the PipeReader
- FlushResult flushResult = await writer.FlushAsync();
+ FlushResult flushResult = await writer.FlushAsync().ConfigureAwait(false);
if (flushResult.IsCompleted)
{
// The PipeReader stopped reading
@@ -223,7 +223,7 @@ namespace Emby.Server.Implementations.HttpServer
if (info.MessageType.Equals("KeepAlive", StringComparison.Ordinal))
{
- await SendKeepAliveResponse();
+ await SendKeepAliveResponse().ConfigureAwait(false);
}
else
{