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/stdlib/strtoll.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/stdlib/strtoll.c') diff --git a/src/stdlib/strtoll.c b/src/stdlib/strtoll.c index 10f05209..ab5b3d9e 100644 --- a/src/stdlib/strtoll.c +++ b/src/stdlib/strtoll.c @@ -2,6 +2,7 @@ #include #include #include +#include #include "_stdlib.h" long long int strtoll(const char * restrict nptr, char ** restrict endptr, int base) @@ -11,6 +12,7 @@ long long int strtoll(const char * restrict nptr, char ** restrict endptr, int b long long int min = LLONG_MIN; SIGNAL_SAFE(0); + ASSERT_NOOVERLAP(nptr, strlen(nptr), endptr, sizeof(*endptr)); #include "_strtoi.h" -- cgit v1.2.1