aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Server/SocketSharp/RequestMono.cs
diff options
context:
space:
mode:
authorBond-009 <bond.009@outlook.com>2019-02-13 17:28:04 +0100
committerBond-009 <bond.009@outlook.com>2019-02-16 00:43:56 +0100
commit46897aab4f85bd2ea50e0ff1ef57c0cfa8f48c67 (patch)
treeeca2f84bb47e013d081e88fe580e2041504c1d6b /Jellyfin.Server/SocketSharp/RequestMono.cs
parent892787cb1a72303ffd514971d0d5ea4c30f2dcd1 (diff)
More warnings
Diffstat (limited to 'Jellyfin.Server/SocketSharp/RequestMono.cs')
-rw-r--r--Jellyfin.Server/SocketSharp/RequestMono.cs9
1 files changed, 2 insertions, 7 deletions
diff --git a/Jellyfin.Server/SocketSharp/RequestMono.cs b/Jellyfin.Server/SocketSharp/RequestMono.cs
index 584d38bcb..9a0601750 100644
--- a/Jellyfin.Server/SocketSharp/RequestMono.cs
+++ b/Jellyfin.Server/SocketSharp/RequestMono.cs
@@ -431,13 +431,13 @@ namespace Jellyfin.Server.SocketSharp
real = position + d;
break;
default:
- throw new ArgumentException(nameof(origin));
+ throw new ArgumentException("Unknown SeekOrigin value", nameof(origin));
}
long virt = real - offset;
if (virt < 0 || virt > Length)
{
- throw new ArgumentException();
+ throw new ArgumentException("Invalid position", nameof(origin));
}
position = s.Seek(real, SeekOrigin.Begin);
@@ -572,11 +572,6 @@ namespace Jellyfin.Server.SocketSharp
public HttpMultipart(Stream data, string b, Encoding encoding)
{
this.data = data;
- // DB: 30/01/11: cannot set or read the Position in HttpListener in Win.NET
- // var ms = new MemoryStream(32 * 1024);
- // data.CopyTo(ms);
- // this.data = ms;
-
boundary = b;
boundary_bytes = encoding.GetBytes(b);
buffer = new byte[boundary_bytes.Length + 2]; // CRLF or '--'