return false;
}
- const auto* us = d_storage.cbegin();
- const auto* p = wire_uncompressed.cbegin();
- for (; us != d_storage.cend() && p != wire_uncompressed.cend(); ++us, ++p) {
- if (dns_tolower(*p) != dns_tolower(*us)) {
+ const auto* our = d_storage.cbegin();
+ const auto* other = wire_uncompressed.cbegin();
+ for (; our != d_storage.cend() && other != wire_uncompressed.cend(); ++our, ++other) {
+ if (dns_tolower(*other) != dns_tolower(*our)) {
return false;
}
}
- return us == d_storage.cend();
+ return our == d_storage.cend();
}
#if defined(PDNS_AUTH) // [
GenericDNSPacketWriter<PacketBuffer> packetWriter(query, aroot, QType::A, QClass::IN, 0);
{
+ // NOLINTNEXTLINE(cppcoreguidelines-pro-type-reinterpret-cast)
const std::string_view raw(reinterpret_cast<const char*>(query.data()) + sizeof(dnsheader), query.size() - sizeof(dnsheader));
BOOST_CHECK(aroot.matches(raw));
{
/* too short */
+ // NOLINTNEXTLINE(cppcoreguidelines-pro-type-reinterpret-cast,cppcoreguidelines-pro-bounds-pointer-arithmetic)
const std::string_view raw(reinterpret_cast<const char*>(query.data() + sizeof(dnsheader)), aroot.wirelength() - 1);
BOOST_CHECK(!(aroot.matches(raw)));
}