From 478eba2a3392c46b12cd5abf433ac4442d7515b7 Mon Sep 17 00:00:00 2001 From: Amos Jeffries Date: Wed, 19 Apr 2023 14:55:13 +0000 Subject: [PATCH] WCCP: fix inverted range check (#1323) Correct a typo in 464223c147a568169e940fb466947bdb556d87af --- src/wccp2.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wccp2.cc b/src/wccp2.cc index df307dcabc..d46a5f8264 100644 --- a/src/wccp2.cc +++ b/src/wccp2.cc @@ -1452,7 +1452,7 @@ wccp2HandleUdp(int sock, void *) ptr += sizeof(*routerCountRaw); const auto ipCount = ntohl(*routerCountRaw); const auto ipsSize = ipCount * sizeof(struct in_addr); // we check for unsigned overflow below - Must3(ipsSize / sizeof(struct in_addr) != ipCount, "huge IP address count", Here()); + Must3(ipsSize / sizeof(struct in_addr) == ipCount, "huge IP address count", Here()); CheckSectionLength(ptr, ipsSize, router_view_header, router_view_size, "invalid IP address count"); ptr += ipsSize; -- 2.47.2