[Modify] Polish it
This commit is contained in:
parent
f05c916ac3
commit
7d038db8a8
@ -492,8 +492,13 @@ namespace WebSocketSharp.Net
|
||||
)
|
||||
{
|
||||
lock (_contextRegistrySync) {
|
||||
if (!_listening)
|
||||
throw new HttpListenerException (995);
|
||||
if (!_listening) {
|
||||
var msg = _disposed
|
||||
? "The listener is closed."
|
||||
: "The listener is stopped.";
|
||||
|
||||
throw new HttpListenerException (995, msg);
|
||||
}
|
||||
|
||||
var ares = new HttpListenerAsyncResult (callback, state);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user