mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 14:35:26 +00:00
Fix HAVE_SO_REUSEPORT_LB macro name definition
A typo in macro definition caused the load-balanced sockets to be disabled even on platforms with existing support for load-balanced sockets.
This commit is contained in:
@@ -53,7 +53,7 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(SO_REUSEPORT_LB) || (defined(SO_REUSEPORT) && defined(__linux__))
|
#if defined(SO_REUSEPORT_LB) || (defined(SO_REUSEPORT) && defined(__linux__))
|
||||||
#define HAVE_REUSEPORT_LB 1
|
#define HAVE_SO_REUSEPORT_LB 1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@@ -406,7 +406,9 @@ isc_nm_listentcp(isc_nm_t *mgr, isc_nmiface_t *iface,
|
|||||||
isc_nmsocket_t *sock = NULL;
|
isc_nmsocket_t *sock = NULL;
|
||||||
sa_family_t sa_family = iface->addr.type.sa.sa_family;
|
sa_family_t sa_family = iface->addr.type.sa.sa_family;
|
||||||
size_t children_size = 0;
|
size_t children_size = 0;
|
||||||
|
#if !HAVE_SO_REUSEPORT_LB && !defined(WIN32)
|
||||||
uv_os_sock_t fd = -1;
|
uv_os_sock_t fd = -1;
|
||||||
|
#endif
|
||||||
|
|
||||||
REQUIRE(VALID_NM(mgr));
|
REQUIRE(VALID_NM(mgr));
|
||||||
|
|
||||||
|
@@ -450,7 +450,9 @@ isc_nm_listentcpdns(isc_nm_t *mgr, isc_nmiface_t *iface,
|
|||||||
isc_nmsocket_t *sock = NULL;
|
isc_nmsocket_t *sock = NULL;
|
||||||
sa_family_t sa_family = iface->addr.type.sa.sa_family;
|
sa_family_t sa_family = iface->addr.type.sa.sa_family;
|
||||||
size_t children_size = 0;
|
size_t children_size = 0;
|
||||||
|
#if !HAVE_SO_REUSEPORT_LB && !defined(WIN32)
|
||||||
uv_os_sock_t fd = -1;
|
uv_os_sock_t fd = -1;
|
||||||
|
#endif
|
||||||
|
|
||||||
REQUIRE(VALID_NM(mgr));
|
REQUIRE(VALID_NM(mgr));
|
||||||
|
|
||||||
|
@@ -106,7 +106,9 @@ isc_nm_listenudp(isc_nm_t *mgr, isc_nmiface_t *iface, isc_nm_recv_cb_t cb,
|
|||||||
isc_nmsocket_t *sock = NULL;
|
isc_nmsocket_t *sock = NULL;
|
||||||
sa_family_t sa_family = iface->addr.type.sa.sa_family;
|
sa_family_t sa_family = iface->addr.type.sa.sa_family;
|
||||||
size_t children_size = 0;
|
size_t children_size = 0;
|
||||||
|
#if !HAVE_SO_REUSEPORT_LB && !defined(WIN32)
|
||||||
uv_os_sock_t fd = -1;
|
uv_os_sock_t fd = -1;
|
||||||
|
#endif
|
||||||
|
|
||||||
REQUIRE(VALID_NM(mgr));
|
REQUIRE(VALID_NM(mgr));
|
||||||
|
|
||||||
@@ -269,7 +271,7 @@ isc__nm_async_udplisten(isc__networker_t *worker, isc__netievent_t *ev0) {
|
|||||||
uv_bind_flags |= UV_UDP_IPV6ONLY;
|
uv_bind_flags |= UV_UDP_IPV6ONLY;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if HAVE_SO_REUSEPORT_LB || WIN32
|
#if HAVE_SO_REUSEPORT_LB || defined(WIN32)
|
||||||
r = isc_uv_udp_freebind(&sock->uv_handle.udp,
|
r = isc_uv_udp_freebind(&sock->uv_handle.udp,
|
||||||
&sock->parent->iface->addr.type.sa,
|
&sock->parent->iface->addr.type.sa,
|
||||||
uv_bind_flags);
|
uv_bind_flags);
|
||||||
|
Reference in New Issue
Block a user