]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
dnsdist: Apply suggestions from Charles-Henri Bruyand's review (thanks!)
authorRemi Gacogne <remi.gacogne@powerdns.com>
Fri, 18 Aug 2023 06:53:16 +0000 (08:53 +0200)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Thu, 7 Sep 2023 08:56:18 +0000 (10:56 +0200)
pdns/dnsdist-lua.cc
pdns/dnsdist.cc
pdns/dnsdistdist/doh.cc

index d5c27f4de39b7e889647f8f4837aae13af920b95..4dd374f94cc083103ecc227ffc1ad5fe18329152 100644 (file)
@@ -2348,7 +2348,6 @@ static void setupLuaConfig(LuaContext& luaCtx, bool client, bool configCheck)
     if (frontend->d_library == "h2o") {
 #ifdef HAVE_LIBH2OEVLOOP
       frontend = std::make_shared<H2ODOHFrontend>();
-      frontend->d_library = "h2o";
 #else /* HAVE_LIBH2OEVLOOP */
         errlog("DOH bind %s is configured to use libh2o but the library is not available", addr);
         return;
index 19e477ce798fa9f65516af850c73676087a6aa7e..a23c03f0485b43c87e476f02fa069cac59abdad4 100644 (file)
@@ -2584,13 +2584,13 @@ int main(int argc, char** argv)
         cout<<"dns-over-https(";
 #ifdef HAVE_LIBH2OEVLOOP
         cout<<"h2o";
-#ifdef HAVE_NGHTTP2
-        cout<<" ";
-#endif
 #endif /* HAVE_LIBH2OEVLOOP */
+#if defined(HAVE_LIBH2OEVLOOP) && defined(HAVE_NGHTTP2)
+        cout<<" ";
+#endif /* defined(HAVE_LIBH2OEVLOOP) && defined(HAVE_NGHTTP2) */
 #ifdef HAVE_NGHTTP2
         cout<<"nghttp2";
-#endif
+#endif /* HAVE_NGHTTP2 */
         cout<<") ";
 #endif /* HAVE_DNS_OVER_HTTPS */
 #ifdef HAVE_DNSCRYPT
index 4d7f53e92bbdbd0e039f8ab53565296a1a40367a..3111274e26533bab4cb17e476b2f2184bbf2e0f9 100644 (file)
@@ -1618,7 +1618,7 @@ void dohThread(ClientState* clientState)
   }
 }
 
-void DOHUnit::handleUDPResponse(PacketBuffer&& udpResponse, InternalQueryState&& state, [[maybe_unused]] const std::shared_ptr<DownstreamState>& downstream)
+void DOHUnit::handleUDPResponse(PacketBuffer&& udpResponse, InternalQueryState&& state, [[maybe_unused]] const std::shared_ptr<DownstreamState>& downstream_)
 {
   auto dohUnit = std::unique_ptr<DOHUnit>(this);
   dohUnit->ids = std::move(state);