mirror of
https://github.com/php/php-src.git
synced 2026-04-20 22:41:20 +02:00
Fix #8195: strncasecmp returns incorrect value
This commit is contained in:
@@ -1563,7 +1563,7 @@ ZEND_API int zend_binary_strncasecmp(char *s1, uint len1, char *s2, uint len2, u
|
||||
}
|
||||
}
|
||||
|
||||
return len1 - len2;
|
||||
return MIN(length, len1) - MIN(length, len2);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user