From 39941992574f375c018355fe40781811c7bc6eae Mon Sep 17 00:00:00 2001 From: sta Date: Wed, 30 Sep 2020 19:41:47 +0900 Subject: [PATCH] [Modify] Polish it --- websocket-sharp/Net/EndPointManager.cs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/websocket-sharp/Net/EndPointManager.cs b/websocket-sharp/Net/EndPointManager.cs index cce76169..a2091a51 100644 --- a/websocket-sharp/Net/EndPointManager.cs +++ b/websocket-sharp/Net/EndPointManager.cs @@ -98,8 +98,11 @@ namespace WebSocketSharp.Net int port; - if (!Int32.TryParse (pref.Port, out port)) - throw new HttpListenerException (87, "Includes an invalid port."); + if (!Int32.TryParse (pref.Port, out port)) { + var msg = "The URI prefix includes an invalid port."; + + throw new HttpListenerException (87, msg); + } if (!port.IsPortNumber ()) throw new HttpListenerException (87, "Includes an invalid port.");