mirror of
https://github.com/cuberite/libevent.git
synced 2025-09-12 13:58:58 -04:00
Minor fix for IOCP shutdown handling fix
Call setsockopt() on the actual new socket, not on as->s, which was set to INVALID_SOCKET.
This commit is contained in:
parent
2b0b06d7a3
commit
2599b2d5f5
@ -615,7 +615,7 @@ accepted_socket_invoke_user_cb(struct deferred_cb *dcb, void *arg)
|
|||||||
/* We need to call this so getsockname, getpeername, and
|
/* We need to call this so getsockname, getpeername, and
|
||||||
* shutdown work correctly on the accepted socket. */
|
* shutdown work correctly on the accepted socket. */
|
||||||
/* XXXX handle error? */
|
/* XXXX handle error? */
|
||||||
setsockopt(as->s, SOL_SOCKET, SO_UPDATE_ACCEPT_CONTEXT,
|
setsockopt(sock, SOL_SOCKET, SO_UPDATE_ACCEPT_CONTEXT,
|
||||||
(char *)&as->lev->fd, sizeof(&as->lev->fd));
|
(char *)&as->lev->fd, sizeof(&as->lev->fd));
|
||||||
}
|
}
|
||||||
data = lev->user_data;
|
data = lev->user_data;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user