mirror of
https://github.com/isc-projects/bind9.git
synced 2026-02-27 03:51:16 -05:00
Add FreeBSD connection timeout socket option
On FreeBSD, the option to configure connection timeout is called TCP_KEEPINIT, use it to configure the connection timeout there. This also fixes the dangling socket problems in the unit test, so re-enable them.
This commit is contained in:
parent
1d066e4bc5
commit
4adeaab73d
5 changed files with 8 additions and 4 deletions
|
|
@ -2283,6 +2283,10 @@ isc__nm_socket_dontfrag(uv_os_sock_t fd, sa_family_t sa_family) {
|
|||
#define TIMEOUT_TYPE unsigned int
|
||||
#define TIMEOUT_DIV 1
|
||||
#define TIMEOUT_OPTNAME TCP_USER_TIMEOUT
|
||||
#elif defined(TCP_KEEPINIT)
|
||||
#define TIMEOUT_TYPE int
|
||||
#define TIMEOUT_DIV 1000
|
||||
#define TIMEOUT_OPTNAME TCP_KEEPINIT
|
||||
#endif
|
||||
|
||||
isc_result_t
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
* information regarding copyright ownership.
|
||||
*/
|
||||
|
||||
#if HAVE_CMOCKA && defined(__linux__)
|
||||
#if HAVE_CMOCKA
|
||||
#include <sched.h> /* IWYU pragma: keep */
|
||||
#include <setjmp.h>
|
||||
#include <stdarg.h>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
* information regarding copyright ownership.
|
||||
*/
|
||||
|
||||
#if HAVE_CMOCKA && defined(__linux__)
|
||||
#if HAVE_CMOCKA
|
||||
#include <sched.h> /* IWYU pragma: keep */
|
||||
#include <setjmp.h>
|
||||
#include <stdarg.h>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
* information regarding copyright ownership.
|
||||
*/
|
||||
|
||||
#if HAVE_CMOCKA && defined(__linux__)
|
||||
#if HAVE_CMOCKA
|
||||
#include <sched.h> /* IWYU pragma: keep */
|
||||
#include <setjmp.h>
|
||||
#include <stdarg.h>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
* information regarding copyright ownership.
|
||||
*/
|
||||
|
||||
#if HAVE_CMOCKA && defined(__linux__)
|
||||
#if HAVE_CMOCKA
|
||||
#include <sched.h> /* IWYU pragma: keep */
|
||||
#include <setjmp.h>
|
||||
#include <stdarg.h>
|
||||
|
|
|
|||
Loading…
Reference in a new issue