mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-06 16:39:20 +00:00
server: Clear the connection error after a successful connection.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
53ec99daeb
commit
ddb9223915
|
@ -3344,7 +3344,7 @@ static void test_select(void)
|
|||
id = 0xdeadbeef;
|
||||
ret = getsockopt(fdWrite, SOL_SOCKET, SO_ERROR, (char *)&id, &len);
|
||||
ok(!ret, "getsockopt failed with %d\n", WSAGetLastError());
|
||||
todo_wine ok(!id, "got error %u\n", id);
|
||||
ok(!id, "got error %u\n", id);
|
||||
|
||||
closesocket(fdWrite);
|
||||
|
||||
|
|
|
@ -983,7 +983,10 @@ static void sock_dispatch_events( struct sock *sock, enum connection_state prevs
|
|||
|
||||
case SOCK_CONNECTING:
|
||||
if (event & POLLOUT)
|
||||
{
|
||||
post_socket_event( sock, AFD_POLL_BIT_CONNECT, 0 );
|
||||
sock->errors[AFD_POLL_BIT_CONNECT_ERR] = 0;
|
||||
}
|
||||
if (event & (POLLERR | POLLHUP))
|
||||
post_socket_event( sock, AFD_POLL_BIT_CONNECT_ERR, error );
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue