[Modify] Replace it

This commit is contained in:
sta 2017-05-31 15:42:13 +09:00
parent e8a0edfeb7
commit 6cfff97441

View File

@ -1018,25 +1018,7 @@ namespace WebSocketSharp.Server
/// </summary> /// </summary>
public void Stop () public void Stop ()
{ {
string msg; stop (1005, String.Empty);
if (!checkIfAvailable (false, true, false, false, out msg)) {
_log.Error (msg);
return;
}
lock (_sync) {
if (!checkIfAvailable (false, true, false, false, out msg)) {
_log.Error (msg);
return;
}
_state = ServerState.ShuttingDown;
}
_services.Stop (new CloseEventArgs (), true, true);
stopReceiving (5000);
_state = ServerState.Stop;
} }
/// <summary> /// <summary>