[Modify] Add a check

This commit is contained in:
sta 2016-03-31 14:29:30 +09:00
parent 46014466ba
commit 5427c15d94

View File

@ -451,6 +451,9 @@ namespace WebSocketSharp.Net
List<HttpConnection> conns = null; List<HttpConnection> conns = null;
lock (_unregisteredSync) { lock (_unregisteredSync) {
if (_unregistered.Count == 0)
return;
conns = new List<HttpConnection> (_unregistered.Keys); conns = new List<HttpConnection> (_unregistered.Keys);
_unregistered.Clear (); _unregistered.Clear ();
} }