]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
dnsdist: Ensure the runtime configuration is updated in the SNMP thread
authorRemi Gacogne <remi.gacogne@powerdns.com>
Fri, 25 Jul 2025 14:28:56 +0000 (16:28 +0200)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Thu, 28 Aug 2025 09:25:03 +0000 (11:25 +0200)
Signed-off-by: Remi Gacogne <remi.gacogne@powerdns.com>
(cherry picked from commit a7da19df49ebd0745449eb206ca035a18500d251)

pdns/dnsdistdist/dnsdist-snmp.cc

index 9d4a05c1f051eca557bf07974b9a9f345ee1d3e3..1f153236ecb13d64b161cc1e0d201bfc1d671eb2 100644 (file)
@@ -284,7 +284,7 @@ static netsnmp_variable_list* backendStatTable_get_first_data_point(void** loop_
 
   /* get a copy of the shared_ptrs so they are not
      destroyed while we process the request */
-  auto backends = dnsdist::configuration::getCurrentRuntimeConfiguration().d_backends;
+  const auto& backends = dnsdist::configuration::refreshLocalRuntimeConfiguration().d_backends;
   s_servers.clear();
   s_servers.reserve(backends.size());
   for (auto& server : backends) {