*/
isc_result_t
-isc__nm_socket_freebind(uv_os_fd_t fd, sa_family_t sa_family);
+isc__nm_socket_freebind(uv_os_sock_t fd, sa_family_t sa_family);
/*%<
* Set the IP_FREEBIND (or equivalent) socket option on the uv_handle
*/
isc_result_t
-isc__nm_socket_reuseport(uv_os_fd_t fd);
+isc__nm_socket_reuseport(uv_os_sock_t fd);
/*%<
* Set the SO_REUSEPORT (or equivalent) socket option on the fd
*/
isc_result_t
-isc__nm_socket_incoming_cpu(uv_os_fd_t fd);
+isc__nm_socket_incoming_cpu(uv_os_sock_t fd);
/*%<
* Set the SO_INCOMING_CPU socket option on the fd if available
*/
isc_result_t
-isc__nm_socket_dontfrag(uv_os_fd_t fd, sa_family_t sa_family);
+isc__nm_socket_dontfrag(uv_os_sock_t fd, sa_family_t sa_family);
/*%<
* Set the SO_IP_DONTFRAG (or equivalent) socket option of the fd if available
*/
setsockopt(socket, level, name, &(int){ 1 }, sizeof(int))
isc_result_t
-isc__nm_socket_freebind(uv_os_fd_t fd, sa_family_t sa_family) {
+isc__nm_socket_freebind(uv_os_sock_t fd, sa_family_t sa_family) {
/*
* Set the IP_FREEBIND (or equivalent option) on the uv_handle.
*/
}
isc_result_t
-isc__nm_socket_reuseport(uv_os_fd_t fd) {
+isc__nm_socket_reuseport(uv_os_sock_t fd) {
/*
* This is SO_REUSE**** hell:
*
}
isc_result_t
-isc__nm_socket_incoming_cpu(uv_os_fd_t fd) {
+isc__nm_socket_incoming_cpu(uv_os_sock_t fd) {
#ifdef SO_INCOMING_CPU
if (setsockopt_on(fd, SOL_SOCKET, SO_INCOMING_CPU) == -1) {
return (ISC_R_FAILURE);
}
isc_result_t
-isc__nm_socket_dontfrag(uv_os_fd_t fd, sa_family_t sa_family) {
+isc__nm_socket_dontfrag(uv_os_sock_t fd, sa_family_t sa_family) {
/*
* Set the Don't Fragment flag on IP packets
*/
struct sockaddr_storage sname;
int r, flags = 0, snamelen = sizeof(sname);
sa_family_t sa_family;
- uv_os_fd_t fd;
+ uv_os_sock_t fd;
REQUIRE(isc__nm_in_netthread());
REQUIRE(sock->type == isc_nm_tcplistener);
r = uv_tcp_bind(&sock->uv_handle.tcp, &sock->iface->addr.type.sa,
flags);
if (r == UV_EADDRNOTAVAIL &&
- uv_fileno(&sock->uv_handle.handle, &fd) == 0 &&
+ uv_fileno(&sock->uv_handle.handle, (uv_os_fd_t *)&fd) == 0 &&
isc__nm_socket_freebind(fd, sa_family) == ISC_R_SUCCESS)
{
/*