]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
rec: coverity fixes, all minor optimizations 14896/head
authorOtto Moerbeek <otto.moerbeek@open-xchange.com>
Wed, 27 Nov 2024 08:07:39 +0000 (09:07 +0100)
committerOtto Moerbeek <otto.moerbeek@open-xchange.com>
Wed, 27 Nov 2024 08:07:39 +0000 (09:07 +0100)
pdns/recursordist/aggressive_nsec.cc
pdns/recursordist/rec-main.cc
pdns/recursordist/rpzloader.cc

index 388c72001630440662d285b8eb34a84f37804404..e894666d50a58589aab6abf872dfadf9f072adb4 100644 (file)
@@ -350,7 +350,7 @@ void AggressiveNSECCache::insertNSEC(const DNSName& zone, const DNSName& owner,
         ++d_entriesCount;
       }
       else {
-        zoneEntry->d_entries.replace(pair.first, {record.getContent(), signatures, std::move(realOwner), next, qname, record.d_ttl, qtype});
+        zoneEntry->d_entries.replace(pair.first, {record.getContent(), signatures, std::move(realOwner), std::move(next), qname, record.d_ttl, qtype});
       }
     }
     else {
index 8c750d25a8948ff6156d0ae5042de5df360cc0b7..4b9229a7657cf3456b8d2c6e59baddaf183e70dc 100644 (file)
@@ -3588,7 +3588,7 @@ static void activateForwardingCatalogZones(LuaConfigItems& lci)
     auto zone = std::make_shared<CatalogZone>();
     // zoneSizeHint ignored
     zone->setName(DNSName(params.name));
-    fcz.d_catz = zone;
+    fcz.d_catz = std::move(zone);
   }
 }
 
index 6af30447dcec1496180d4fd164f24f8466ed8da1..1ba0c9b6564d3ef9725682dc232389695c358080 100644 (file)
@@ -652,7 +652,7 @@ static bool RPZTrackerIteration(RPZTrackerParams& params, const DNSName& zoneNam
 
     /* only update sr now that all changes have been converted */
     if (currentSR) {
-      newZone->setSOA(dnsRecord);
+      newZone->setSOA(std::move(dnsRecord));
       params.zoneXFRParams.soaRecordContent = std::move(currentSR);
     }
     SLOG(g_log << Logger::Info << "Had " << totremove << " RPZ removal" << addS(totremove) << ", " << totadd << " addition" << addS(totadd) << " for " << zoneName << " New serial: " << params.soaRecordContent->d_st.serial << endl,