diff options
Diffstat (limited to 'lib/libc/string/strcmp.c')
-rw-r--r-- | lib/libc/string/strcmp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libc/string/strcmp.c b/lib/libc/string/strcmp.c index 79cfaa8..cf25e50 100644 --- a/lib/libc/string/strcmp.c +++ b/lib/libc/string/strcmp.c @@ -51,5 +51,5 @@ strcmp(s1, s2) while (*s1 == *s2++) if (*s1++ == 0) return (0); - return (*(unsigned char *)s1 - *(unsigned char *)--s2); + return (*(const unsigned char *)s1 - *(const unsigned char *)(s2 - 1)); } |