tcp: set is_connected flag on our socket without parent too.

a client non-blocking socket would otherwise looks non connected.

Change-Id: I077c0b61a5dbaa8df350185c8a9259fd81dab342
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2553
Reviewed-by: waddlesplash <[email protected]>
This commit is contained in:
Jérôme Duval
2020-05-02 18:06:56 +00:00
committed by waddlesplash
parent 96240a75f1
commit 86ff706f30
@@ -1217,10 +1217,9 @@ TCPEndpoint::_MarkEstablished()
fState = ESTABLISHED;
T(State(this));
if (gSocketModule->has_parent(socket)) {
gSocketModule->set_connected(socket);
gSocketModule->set_connected(socket);
if (gSocketModule->has_parent(socket))
release_sem_etc(fAcceptSemaphore, 1, B_DO_NOT_RESCHEDULE);
}
fSendCondition.NotifyAll();
gSocketModule->notify(socket, B_SELECT_WRITE, fSendQueue.Free());