disable socket mutex usage in WebSocketTransport

This commit is contained in:
Benjamin Sergeant 2019-05-16 15:46:32 -07:00
parent 616447e01d
commit c131ff2662

View File

@ -142,7 +142,7 @@ namespace ix
std::string errorMsg;
{
bool tls = protocol == "wss";
std::lock_guard<std::mutex> lock(_socketMutex);
// std::lock_guard<std::mutex> lock(_socketMutex);
_socket = createSocket(tls, errorMsg);
if (!_socket)
@ -174,7 +174,7 @@ namespace ix
std::string errorMsg;
{
std::lock_guard<std::mutex> lock(_socketMutex);
// std::lock_guard<std::mutex> lock(_socketMutex);
_socket = createSocket(fd, errorMsg);
if (!_socket)
@ -962,7 +962,7 @@ namespace ix
ssize_t WebSocketTransport::send()
{
std::lock_guard<std::mutex> lock(_socketMutex);
// std::lock_guard<std::mutex> lock(_socketMutex);
return _socket->send((char*)&_txbuf[0], _txbuf.size());
}
@ -1016,7 +1016,7 @@ namespace ix
void WebSocketTransport::closeSocket()
{
std::lock_guard<std::mutex> lock(_socketMutex);
// std::lock_guard<std::mutex> lock(_socketMutex);
_socket->close();
}