[Modify] Polish it

This commit is contained in:
sta 2016-10-14 15:52:15 +09:00
parent 3c1c3c5aa8
commit 34d61cd8f5

View File

@ -558,8 +558,14 @@ namespace WebSocketSharp.Server
} }
set { set {
var msg = _state.CheckIfAvailable (true, false, false); string msg;
if (msg != null) { if (!checkIfAvailable (true, false, false, true, out msg)) {
_logger.Error (msg);
return;
}
lock (_sync) {
if (!checkIfAvailable (true, false, false, true, out msg)) {
_logger.Error (msg); _logger.Error (msg);
return; return;
} }
@ -567,6 +573,7 @@ namespace WebSocketSharp.Server
_userCredFinder = value; _userCredFinder = value;
} }
} }
}
/// <summary> /// <summary>
/// Gets or sets the wait time for the response to the WebSocket Ping or Close. /// Gets or sets the wait time for the response to the WebSocket Ping or Close.