From b668e52c906b664b353d5a99cfa3ff36f73b341d Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Sun, 15 Feb 2026 14:41:20 +0100 Subject: *: placate warnings where strchr/strstr returns constant pointer Newer glibc is now smarter and can propagate const-ness from those! function old new delta readtoken1 3111 3108 -3 Signed-off-by: Denys Vlasenko --- libbb/replace.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'libbb/replace.c') diff --git a/libbb/replace.c b/libbb/replace.c index bc26b04cc..273330f8a 100644 --- a/libbb/replace.c +++ b/libbb/replace.c @@ -28,7 +28,8 @@ unsigned FAST_FUNC count_strstr(const char *str, const char *sub) char* FAST_FUNC xmalloc_substitute_string(const char *src, int count, const char *sub, const char *repl) { - char *buf, *dst, *end; + char *buf, *dst; + const char *end; size_t sub_len = strlen(sub); size_t repl_len = strlen(repl); -- cgit v1.2.3-55-g6feb