[Modify] Polish it
This commit is contained in:
parent
7dbdeafca2
commit
04308645b5
@ -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 {
|
||||||
|
Loading…
Reference in New Issue
Block a user