From 4a0eb0370c4df8ee01973b50bb460560532b79f1 Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Thu, 1 Oct 2020 03:07:22 +0200 Subject: gcc-9.x warning fixes Signed-off-by: Denys Vlasenko --- libbb/inet_cksum.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'libbb') diff --git a/libbb/inet_cksum.c b/libbb/inet_cksum.c index 3d5dc3a..fee8648 100644 --- a/libbb/inet_cksum.c +++ b/libbb/inet_cksum.c @@ -6,8 +6,10 @@ #include "libbb.h" -uint16_t FAST_FUNC inet_cksum(uint16_t *addr, int nleft) +uint16_t FAST_FUNC inet_cksum(const void *ptr, int nleft) { + const uint16_t *addr = ptr; + /* * Our algorithm is simple, using a 32 bit accumulator, * we add sequential 16 bit words to it, and at the end, fold -- cgit v1.1