[Modify] Polish it

This commit is contained in:
sta 2017-08-27 14:51:55 +09:00
parent 53af874011
commit 048e39a915

View File

@ -289,10 +289,13 @@ namespace WebSocketSharp.Server
private void broadcast (Opcode opcode, Stream stream, Action completed)
{
var cache = new Dictionary<CompressionMethod, Stream> ();
try {
foreach (var host in Hosts) {
if (_state != ServerState.Start)
if (_state != ServerState.Start) {
_log.Error ("The server is shutting down.");
break;
}
host.Sessions.Broadcast (opcode, stream, cache);
}