]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
Bunch of signed vs unsigned warnings 9937/head
authorOtto <otto.moerbeek@open-xchange.com>
Mon, 11 Jan 2021 15:21:03 +0000 (16:21 +0100)
committerOtto <otto.moerbeek@open-xchange.com>
Mon, 11 Jan 2021 15:21:03 +0000 (16:21 +0100)
pdns/calidns.cc
pdns/recursordist/test-syncres_cc7.cc
pdns/test-dnsdist_cc.cc

index d07ac19f4ad440a2b5b942c2f500000d2debd967..df9307798173039b71350273c9ed61dfa7e0156e 100644 (file)
@@ -108,7 +108,7 @@ static void* recvThread(const vector<std::unique_ptr<Socket>>* sockets)
           continue;
         }
         g_recvcounter++;
-        for (unsigned int i = 0; i < buf.msg_iovlen; i++)
+        for (int i = 0; i < buf.msg_iovlen; i++)
           g_recvbytes += buf.msg_iov[i].iov_len;
 #endif
       }
index d1341945e036915fd48365f76b94d62e5a3395fc..4641f96b7f077db7ca6abe78d9b4559003eae11d 100644 (file)
@@ -1583,7 +1583,7 @@ BOOST_AUTO_TEST_CASE(test_dnssec_secure_to_insecure_cut_with_cname_at_apex)
   BOOST_CHECK_EQUAL(queriesCount, 11U);
 
   /* now we remove the denial of powerdns.com DS from the cache and ask www2 */
-  BOOST_REQUIRE_EQUAL(g_negCache->wipe(target, false), 1);
+  BOOST_REQUIRE_EQUAL(g_negCache->wipe(target, false), 1U);
   ret.clear();
   res = sr->beginResolve(DNSName("www2.powerdns.com."), QType(QType::A), QClass::IN, ret);
   BOOST_CHECK_EQUAL(res, RCode::NoError);
@@ -1706,7 +1706,7 @@ BOOST_AUTO_TEST_CASE(test_dnssec_cname_inside_secure_zone)
   BOOST_CHECK_EQUAL(queriesCount, 10U);
 
   /* now we remove the denial of powerdns.com DS from the cache and ask www2 */
-  BOOST_REQUIRE_EQUAL(g_negCache->wipe(target, false), 1);
+  BOOST_REQUIRE_EQUAL(g_negCache->wipe(target, false), 1U);
   ret.clear();
   res = sr->beginResolve(DNSName("www2.powerdns.com."), QType(QType::A), QClass::IN, ret);
   BOOST_CHECK_EQUAL(res, RCode::NoError);
index f17e3992810fa032955b30888ad2fcd1b0489b08..638c74a735b899b44ebf0f0531297448c8fc5f1c 100644 (file)
@@ -135,7 +135,7 @@ BOOST_AUTO_TEST_CASE(test_addXPF)
     DNSQuestion dq(&qname, qtype, QClass::IN, &remote, &remote, packet, false, &queryTime);
 
     BOOST_REQUIRE(!addXPF(dq, xpfOptionCode));
-    BOOST_CHECK_EQUAL(packet.size(), 4096);
+    BOOST_CHECK_EQUAL(packet.size(), 4096U);
     packet.resize(query.size());
     validateQuery(packet, false, false);
   }
@@ -286,7 +286,7 @@ BOOST_AUTO_TEST_CASE(addECSWithoutEDNSAlreadyParsed)
 
   BOOST_CHECK(handleEDNSClientSubnet(dq2, ednsAdded, ecsAdded));
   BOOST_CHECK_GT(packet.size(), query.size());
-  BOOST_CHECK_LT(packet.size(), 2048);
+  BOOST_CHECK_LT(packet.size(), 2048U);
   BOOST_CHECK_EQUAL(ednsAdded, true);
   BOOST_CHECK_EQUAL(ecsAdded, true);
   validateQuery(packet);
@@ -387,7 +387,7 @@ BOOST_AUTO_TEST_CASE(addECSWithEDNSNoECSAlreadyParsed) {
 
   BOOST_CHECK(handleEDNSClientSubnet(dq2, ednsAdded, ecsAdded));
   BOOST_CHECK_GT(packet.size(), query.size());
-  BOOST_CHECK_LT(packet.size(), 2048);
+  BOOST_CHECK_LT(packet.size(), 2048U);
   BOOST_CHECK_EQUAL(ednsAdded, false);
   BOOST_CHECK_EQUAL(ecsAdded, true);
   validateQuery(packet);