From: Remi Gacogne Date: Mon, 8 Jul 2024 12:58:20 +0000 (+0200) Subject: dnsdist: Fix code formatting X-Git-Tag: rec-5.2.0-alpha1~179^2~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9d0e129b7b576604a3bf7c338647b31447de72ae;p=thirdparty%2Fpdns.git dnsdist: Fix code formatting --- diff --git a/pdns/xsk.cc b/pdns/xsk.cc index 5178a03a08..f2757ebe3c 100644 --- a/pdns/xsk.cc +++ b/pdns/xsk.cc @@ -88,7 +88,7 @@ void checkUmemIntegrity(const char* function, int line, std::shared_ptrat({vect.get(), offset}).status) == 0) { - std::cerr << "UMEM integrity check failed at " << function << ": " << line << ": status of "<<(void*)vect.get()<<", "<(umems->at({vect.get(), offset}).status) << ", expected: "; + std::cerr << "UMEM integrity check failed at " << function << ": " << line << ": status of " << (void*)vect.get() << ", " << offset << " is " << static_cast(umems->at({vect.get(), offset}).status) << ", expected: "; for (const auto status : validStatuses) { std::cerr << static_cast(status) << " "; } @@ -918,7 +918,7 @@ void XskPacket::rewrite() noexcept /* needed to get the correct checksum */ setIPv4Header(ipHeader); setUDPHeader(udpHeader); - //udpHeader.check = tcp_udp_v4_checksum(&ipHeader); + // udpHeader.check = tcp_udp_v4_checksum(&ipHeader); rewriteIpv4Header(&ipHeader, getFrameLen()); setIPv4Header(ipHeader); setUDPHeader(udpHeader); diff --git a/pdns/xsk.hh b/pdns/xsk.hh index df312e399e..fdb9a24d1a 100644 --- a/pdns/xsk.hh +++ b/pdns/xsk.hh @@ -275,7 +275,11 @@ bool operator<(const XskPacket& lhs, const XskPacket& rhs) noexcept; class XskWorker { public: - enum class Type : uint8_t { OutgoingOnly, Bidirectional}; + enum class Type : uint8_t + { + OutgoingOnly, + Bidirectional + }; private: using XskPacketRing = boost::lockfree::spsc_queue>;