aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/Net/UdpSocket.cs
diff options
context:
space:
mode:
authorBond-009 <bond.009@outlook.com>2022-09-12 01:56:41 +0200
committerGitHub <noreply@github.com>2022-09-11 17:56:41 -0600
commit2d57e71b4446df7274ae3a9bc45421f890c1bdd2 (patch)
tree068ffd01de5f027f914c3adb96ece9b50af73240 /Emby.Server.Implementations/Net/UdpSocket.cs
parentd2e18547b16fa30684d7c9ceb8a117d5d9bcef56 (diff)
Don't allow throwing System.Exception (#8378)
Diffstat (limited to 'Emby.Server.Implementations/Net/UdpSocket.cs')
-rw-r--r--Emby.Server.Implementations/Net/UdpSocket.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/Emby.Server.Implementations/Net/UdpSocket.cs b/Emby.Server.Implementations/Net/UdpSocket.cs
index bbbca4fc0..2c20daa57 100644
--- a/Emby.Server.Implementations/Net/UdpSocket.cs
+++ b/Emby.Server.Implementations/Net/UdpSocket.cs
@@ -96,7 +96,7 @@ namespace Emby.Server.Implementations.Net
}
else
{
- tcs.TrySetException(new Exception("SocketError: " + e.SocketError));
+ tcs.TrySetException(new SocketException((int)e.SocketError));
}
}
}
@@ -114,7 +114,7 @@ namespace Emby.Server.Implementations.Net
}
else
{
- tcs.TrySetException(new Exception("SocketError: " + e.SocketError));
+ tcs.TrySetException(new SocketException((int)e.SocketError));
}
}
}