From 59f51380a63b9a143b2a1441c3a6427762fe59db Mon Sep 17 00:00:00 2001 From: sta Date: Wed, 12 Dec 2018 20:19:15 +0900 Subject: [PATCH] [Modify] Throw exception --- websocket-sharp/Net/HttpUtility.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/websocket-sharp/Net/HttpUtility.cs b/websocket-sharp/Net/HttpUtility.cs index e3098289..df7b3b90 100644 --- a/websocket-sharp/Net/HttpUtility.cs +++ b/websocket-sharp/Net/HttpUtility.cs @@ -945,7 +945,10 @@ namespace WebSocketSharp.Net public static string UrlDecode (string s, Encoding encoding) { - if (s == null || s.Length == 0 || !s.Contains ('%', '+')) + if (s == null) + throw new ArgumentNullException ("s"); + + if (s.Length == 0) return s; if (encoding == null)