]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
dnsdist: Fix a clang-tidy warning with opcodes 13372/head
authorRemi Gacogne <remi.gacogne@powerdns.com>
Thu, 19 Oct 2023 09:39:03 +0000 (11:39 +0200)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Thu, 19 Oct 2023 09:39:03 +0000 (11:39 +0200)
pdns/dnscrypt.cc

index 192dcfad1802d652476402fe30ee382a692b3b4b..372329bdfcc03d2a2dda8af25c780c34a8f50bef 100644 (file)
@@ -400,7 +400,7 @@ bool DNSCryptQuery::parsePlaintextQuery(const PacketBuffer& packet)
   }
 
   const dnsheader_aligned dh(packet.data());
-  if (dh->qr || ntohs(dh->qdcount) != 1 || dh->ancount != 0 || dh->nscount != 0 || dh->opcode != Opcode::Query) {
+  if (dh->qr || ntohs(dh->qdcount) != 1 || dh->ancount != 0 || dh->nscount != 0 || static_cast<uint8_t>(dh->opcode) != Opcode::Query) {
     return false;
   }