[Modify] Polish it

This commit is contained in:
sta 2021-08-28 21:02:53 +09:00
parent 7dbdeafca2
commit 04308645b5

View File

@ -933,11 +933,13 @@ namespace WebSocketSharp.Server
lock (_sync) { lock (_sync) {
if (_state == ServerState.ShuttingDown) { if (_state == ServerState.ShuttingDown) {
_log.Info ("The server is shutting down."); _log.Info ("The server is shutting down.");
return; return;
} }
if (_state == ServerState.Stop) { if (_state == ServerState.Stop) {
_log.Info ("The server has already stopped."); _log.Info ("The server has already stopped.");
return; return;
} }
@ -946,11 +948,13 @@ namespace WebSocketSharp.Server
try { try {
var threw = false; var threw = false;
try { try {
stopReceiving (5000); stopReceiving (5000);
} }
catch { catch {
threw = true; threw = true;
throw; throw;
} }
finally { finally {