Fix for issue #45
This commit is contained in:
parent
cae324a936
commit
be85033f8a
@ -1427,7 +1427,13 @@ namespace WebSocketSharp
|
||||
|
||||
internal bool Ping (byte [] frame, int timeout)
|
||||
{
|
||||
return send (frame) && _receivePong.WaitOne (timeout);
|
||||
try {
|
||||
var pong = _receivePong;
|
||||
return send (frame) && pong != null && pong.WaitOne (timeout);
|
||||
}
|
||||
catch {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// As server, used to broadcast
|
||||
|
Loading…
Reference in New Issue
Block a user