From f1d0586270af450c8a05da245dc3802545850520 Mon Sep 17 00:00:00 2001 From: sta Date: Tue, 1 Nov 2016 15:52:05 +0900 Subject: [PATCH] [Modify] Polish it --- websocket-sharp/WebSocket.cs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/websocket-sharp/WebSocket.cs b/websocket-sharp/WebSocket.cs index 602ddb9d..364ad1ca 100644 --- a/websocket-sharp/WebSocket.cs +++ b/websocket-sharp/WebSocket.cs @@ -310,9 +310,16 @@ namespace WebSocketSharp } set { + string msg; + if (!checkIfAvailable (true, false, true, false, false, true, out msg)) { + _logger.Error (msg); + error ("An error has occurred in setting the compression.", null); + + return; + } + lock (_forState) { - string msg; - if (!checkIfAvailable (true, false, true, false, false, true, out msg)) { + if (!checkIfAvailable (true, false, false, true, out msg)) { _logger.Error (msg); error ("An error has occurred in setting the compression.", null);