From 0ae7d128bd5a3ddcea11341467b18749369cc00c Mon Sep 17 00:00:00 2001 From: Greg Haerr Date: Sun, 22 Dec 2024 19:30:05 -0700 Subject: [PATCH] [libc] Fix libc OpenWatcom memcmp routine --- libc/string/memcmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libc/string/memcmp.c b/libc/string/memcmp.c index be76fae05..fd1dc747b 100644 --- a/libc/string/memcmp.c +++ b/libc/string/memcmp.c @@ -5,7 +5,7 @@ memcmp(const void *s1, const void *s2, size_t n) { const unsigned char *su1 = s1; const unsigned char *su2 = s2; - char res = 0; + signed char res = 0; for (; n > 0; n--) if ((res = *su1++ - *su2++))