add cancellation support while connecting, to speed up WebSocket::stop
This commit is contained in:
1 parent
62528e6a0b
commit
8c079787f0
13 files changed
+69
-25
No files matched your search
@@ -191,7 +191,12 @@ namespace ix
|
||||
}
|
||||
|
||||
std::string errMsg;
|
||||
bool success = _socket->connect(host, port, errMsg);
|
||||
bool success = _socket->connect(host, port, errMsg,
|
||||
[this]
|
||||
{
|
||||
return _readyState == CLOSING;
|
||||
}
|
||||
);
|
||||
if (!success)
|
||||
{
|
||||
std::stringstream ss;
|
||||
|
||||
Reference in new issue
Block a user