aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEd Maste <emaste@FreeBSD.org>2022-01-16 16:50:10 +0000
committerEd Maste <emaste@FreeBSD.org>2022-01-16 16:52:29 +0000
commitc6750f07b43d18d39729570533f4ecb56da286bf (patch)
treeacd45e6fc817f515182c58528563e50c5bb329de
parent4ca41937606064c78a4f5725bb0b2ba021cfd7c3 (diff)
downloadsrc-c6750f07b43d18d39729570533f4ecb56da286bf.tar.gz
src-c6750f07b43d18d39729570533f4ecb56da286bf.zip
libc: fix misleading comment in strstr
Obtained from: musl c53e9b239418
-rw-r--r--lib/libc/string/strstr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libc/string/strstr.c b/lib/libc/string/strstr.c
index 72f8abb9e200..ce06db11f161 100644
--- a/lib/libc/string/strstr.c
+++ b/lib/libc/string/strstr.c
@@ -149,7 +149,7 @@ twoway_strstr(const unsigned char *h, const unsigned char *n)
for (;;) {
/* Update incremental end-of-haystack pointer */
if (z - h < l) {
- /* Fast estimate for MIN(l,63) */
+ /* Fast estimate for MAX(l,63) */
size_t grow = l | 63;
const unsigned char *z2 = memchr(z, 0, grow);
if (z2) {