From 20f67fee9447069d4586a41254468ac060b2d65e Mon Sep 17 00:00:00 2001 From: Remi Gacogne Date: Mon, 15 May 2023 15:32:27 +0200 Subject: [PATCH] dnsdist: Really disable REUSEADDR on outgoing UDP client sockets It turns out that our `Socket::bind()` will _helpfully_ enable this by default. --- pdns/dnsdistdist/dnsdist-healthchecks.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pdns/dnsdistdist/dnsdist-healthchecks.cc b/pdns/dnsdistdist/dnsdist-healthchecks.cc index 9ec50e3a5a..213374020f 100644 --- a/pdns/dnsdistdist/dnsdist-healthchecks.cc +++ b/pdns/dnsdistdist/dnsdist-healthchecks.cc @@ -327,7 +327,7 @@ bool queueHealthCheck(std::unique_ptr& mplexer, const std::shared SSetsockopt(sock.getHandle(), SOL_IP, IP_BIND_ADDRESS_NO_PORT, 1); } #endif - sock.bind(ds->d_config.sourceAddr); + sock.bind(ds->d_config.sourceAddr, false); } auto data = std::make_shared(*mplexer, ds, std::move(checkName), checkType, checkClass, queryID); -- 2.47.2