Codechange: ensure OnConnect() always gets called with a valid socket (#9729)
This should already be the case, but now assert()s will tell us if this isn't.
This commit is contained in:
@@ -451,6 +451,8 @@ bool TCPServerConnecter::CheckActivity()
|
||||
*/
|
||||
void TCPServerConnecter::SetConnected(SOCKET sock)
|
||||
{
|
||||
assert(sock != INVALID_SOCKET);
|
||||
|
||||
this->socket = sock;
|
||||
this->status = Status::CONNECTED;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user