File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -500,8 +500,10 @@ ZEND_API zend_string *zend_string_concat3(
500500 return res ;
501501}
502502
503- /* strlcpy and strlcat are not intercepted by msan, so we need to do it ourselves. */
504- #if __has_feature (memory_sanitizer )
503+ /* strlcpy and strlcat are not always intercepted by msan, so we need to do it
504+ * ourselves. Apply a simple heuristic to determine the platforms that need it.
505+ * See https://github.com/php/php-src/issues/20002. */
506+ #if __has_feature (memory_sanitizer ) && !defined(__FreeBSD__ ) && !defined(__NetBSD__ ) && !defined(__APPLE__ )
505507static size_t (* libc_strlcpy )(char * __restrict, const char * __restrict, size_t );
506508size_t strlcpy (char * __restrict dest , const char * __restrict src , size_t n )
507509{
You can’t perform that action at this time.
0 commit comments