From 4b43b375b7abae22070cd86bfc26a8222233150e Mon Sep 17 00:00:00 2001 From: Jakob Kaivo Date: Wed, 31 Jan 2024 13:24:56 -0500 Subject: check for overlapping pointers --- src/string/strcmp.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/string/strcmp.c') diff --git a/src/string/strcmp.c b/src/string/strcmp.c index 8c679f4b..58102d79 100644 --- a/src/string/strcmp.c +++ b/src/string/strcmp.c @@ -8,6 +8,7 @@ int strcmp(const char *s1, const char *s2) SIGNAL_SAFE(0); ASSERT_NONNULL(s1); ASSERT_NONNULL(s2); + /* no modifcation, overlap is OK */ while (*s1 && *s2) { if (*s1 != *s2) { -- cgit v1.2.1