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