diff --git a/pdns/dnsdistdist/dnsdist-discovery.cc b/pdns/dnsdistdist/dnsdist-discovery.cc index 9c065e3569834..07a2a85c6e70f 100644 --- a/pdns/dnsdistdist/dnsdist-discovery.cc +++ b/pdns/dnsdistdist/dnsdist-discovery.cc @@ -462,8 +462,8 @@ bool ServiceDiscovery::tryToUpgradeBackend(const UpgradeableBackend& backend) /* remove the existing backend if needed */ if (!backend.keepAfterUpgrade) { - dnsdist::configuration::updateRuntimeConfiguration([&backend](dnsdist::configuration::RuntimeConfiguration& config) { - auto& backends = config.d_backends; + dnsdist::configuration::updateRuntimeConfiguration([&backend](dnsdist::configuration::RuntimeConfiguration& runtimeConfig) { + auto& backends = runtimeConfig.d_backends; for (auto backendIt = backends.begin(); backendIt != backends.end(); ++backendIt) { if (*backendIt == backend.d_ds) { backends.erase(backendIt); diff --git a/pdns/dnsdistdist/dnsdist.cc b/pdns/dnsdistdist/dnsdist.cc index 2899db02ba2d5..9a6e31aa57d2a 100644 --- a/pdns/dnsdistdist/dnsdist.cc +++ b/pdns/dnsdistdist/dnsdist.cc @@ -3436,8 +3436,8 @@ int main(int argc, char** argv) auto ret = std::make_shared(std::move(config), nullptr, true); addServerToPool("", ret); ret->start(); - dnsdist::configuration::updateRuntimeConfiguration([&ret](dnsdist::configuration::RuntimeConfiguration& config) { - config.d_backends.push_back(std::move(ret)); + dnsdist::configuration::updateRuntimeConfiguration([&ret](dnsdist::configuration::RuntimeConfiguration& runtimeConfig) { + runtimeConfig.d_backends.push_back(std::move(ret)); }); } }