From: Paul Smith Date: Sat, 24 Sep 2022 14:46:55 +0000 (-0400) Subject: * src/misc.c (strncasecmp): Use size_t for length to match std. X-Git-Tag: 4.3.91~41 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=cf7f7de7ae62e85102920e5e63cbfe8c5aaf7f88;p=thirdparty%2Fmake.git * src/misc.c (strncasecmp): Use size_t for length to match std. * src/misc.h (strncasecmp): Fix the declaration. --- diff --git a/src/makeint.h b/src/makeint.h index 54b500f3..a9cc864f 100644 --- a/src/makeint.h +++ b/src/makeint.h @@ -675,7 +675,7 @@ int strcasecmp (const char *s1, const char *s2); # define strncasecmp strncmpi # else /* Create our own, in misc.c */ -int strncasecmp (const char *s1, const char *s2, int n); +int strncasecmp (const char *s1, const char *s2, size_t n); # endif #endif diff --git a/src/misc.c b/src/misc.c index 597e7a33..c309084e 100644 --- a/src/misc.c +++ b/src/misc.c @@ -688,7 +688,7 @@ strcasecmp (const char *s1, const char *s2) substitute for it, define our own version. */ int -strncasecmp (const char *s1, const char *s2, int n) +strncasecmp (const char *s1, const char *s2, size_t n) { while (n-- > 0) {