diff options
Diffstat (limited to 'source4/lib/socket')
-rw-r--r-- | source4/lib/socket/socket_ipv4.c | 2 | ||||
-rw-r--r-- | source4/lib/socket/socket_ipv6.c | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/source4/lib/socket/socket_ipv4.c b/source4/lib/socket/socket_ipv4.c index aaa5ce0fa2..09a4b4a73a 100644 --- a/source4/lib/socket/socket_ipv4.c +++ b/source4/lib/socket/socket_ipv4.c @@ -139,6 +139,8 @@ static NTSTATUS ipv4_listen(struct socket_context *sock, struct ipv4_addr ip_addr; int ret; + socket_set_option(sock, "SO_REUSEADDR=1", NULL); + ip_addr = interpret_addr2(my_address); ZERO_STRUCT(my_addr); diff --git a/source4/lib/socket/socket_ipv6.c b/source4/lib/socket/socket_ipv6.c index 1dd7fe8e9d..f5cd756259 100644 --- a/source4/lib/socket/socket_ipv6.c +++ b/source4/lib/socket/socket_ipv6.c @@ -125,6 +125,8 @@ static NTSTATUS ipv6_tcp_listen(struct socket_context *sock, struct in6_addr ip_addr; int ret; + socket_set_option(sock, "SO_REUSEADDR=1", NULL); + ip_addr = interpret_addr6(my_address); ZERO_STRUCT(my_addr); |