[Modify] Polish it
This commit is contained in:
parent
4ccf6358d0
commit
caa2302608
@ -802,10 +802,12 @@ namespace WebSocketSharp.Net
|
|||||||
public void Stop ()
|
public void Stop ()
|
||||||
{
|
{
|
||||||
CheckDisposed ();
|
CheckDisposed ();
|
||||||
|
|
||||||
if (!_listening)
|
if (!_listening)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
_listening = false;
|
_listening = false;
|
||||||
|
|
||||||
EndPointManager.RemoveListener (this);
|
EndPointManager.RemoveListener (this);
|
||||||
|
|
||||||
lock (_ctxRegistrySync)
|
lock (_ctxRegistrySync)
|
||||||
@ -813,7 +815,9 @@ namespace WebSocketSharp.Net
|
|||||||
|
|
||||||
cleanupContextRegistry ();
|
cleanupContextRegistry ();
|
||||||
cleanupConnections ();
|
cleanupConnections ();
|
||||||
cleanupWaitQueue (new HttpListenerException (995, "The listener is stopped."));
|
|
||||||
|
var ex = new HttpListenerException (995, "The listener is stopped.");
|
||||||
|
cleanupWaitQueue (ex);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
Loading…
Reference in New Issue
Block a user