From 7de8f735dfe82553bac6a5a59207f6e6075e707d Mon Sep 17 00:00:00 2001 From: sta Date: Fri, 1 Dec 2017 16:40:28 +0900 Subject: [PATCH] [Modify] Replace it --- websocket-sharp/WebSocket.cs | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/websocket-sharp/WebSocket.cs b/websocket-sharp/WebSocket.cs index 6b443fe2..907a8111 100644 --- a/websocket-sharp/WebSocket.cs +++ b/websocket-sharp/WebSocket.cs @@ -879,11 +879,10 @@ namespace WebSocketSharp if (!customCheckHandshakeRequest (_context, out msg)) { _logger.Error (msg); - var res = createHandshakeFailureResponse (HttpStatusCode.BadRequest); - sendHttpResponse (res); - - msg = "A handshake error has occurred while attempting to accept."; - fatal (msg, CloseStatusCode.PolicyViolation); + refuseHandshake ( + CloseStatusCode.PolicyViolation, + "A handshake error has occurred while attempting to accept." + ); return false; }