From f0dd2a03e855795176d9d4d8a82dccb5b64cda69 Mon Sep 17 00:00:00 2001 From: sta Date: Wed, 25 Nov 2020 19:37:44 +0900 Subject: [PATCH] [Modify] Add a null check --- websocket-sharp/Net/ClientSslConfiguration.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/websocket-sharp/Net/ClientSslConfiguration.cs b/websocket-sharp/Net/ClientSslConfiguration.cs index 0cae24a6..baccc0cf 100644 --- a/websocket-sharp/Net/ClientSslConfiguration.cs +++ b/websocket-sharp/Net/ClientSslConfiguration.cs @@ -76,7 +76,11 @@ namespace WebSocketSharp.Net /// public ClientSslConfiguration (string targetHost) { + if (targetHost == null) + throw new ArgumentNullException ("targetHost"); + _targetHost = targetHost; + _enabledSslProtocols = SslProtocols.None; }