[Modify] Polish it
This commit is contained in:
parent
27a23446fb
commit
d7b3fef56d
@ -472,19 +472,18 @@ namespace WebSocketSharp.Net
|
||||
private void close (bool force)
|
||||
{
|
||||
if (_listening) {
|
||||
_listening = false;
|
||||
cleanupContextQueue (!force);
|
||||
cleanupContextRegistry ();
|
||||
|
||||
var name = GetType ().ToString ();
|
||||
var ex = new ObjectDisposedException (name);
|
||||
cleanupWaitQueue (ex);
|
||||
|
||||
EndPointManager.RemoveListener (this);
|
||||
|
||||
_listening = false;
|
||||
}
|
||||
|
||||
lock (_contextRegistrySync)
|
||||
cleanupContextQueue (!force);
|
||||
|
||||
cleanupContextRegistry ();
|
||||
|
||||
var ex = new ObjectDisposedException (GetType ().ToString ());
|
||||
cleanupWaitQueue (ex);
|
||||
|
||||
_disposed = true;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user