summaryrefslogtreecommitdiff
path: root/Zend/zend_operators.c
diff options
context:
space:
mode:
Diffstat (limited to 'Zend/zend_operators.c')
-rw-r--r--Zend/zend_operators.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c
index b58eb7eb29..46d7d068f0 100644
--- a/Zend/zend_operators.c
+++ b/Zend/zend_operators.c
@@ -1691,8 +1691,8 @@ ZEND_API int zend_binary_strcasecmp(char *s1, uint len1, char *s2, uint len2)
len = MIN(len1, len2);
while (len--) {
- c1 = tolower(*s1++);
- c2 = tolower(*s2++);
+ c1 = tolower((int)*(unsigned char *)s1++);
+ c2 = tolower((int)*(unsigned char *)s2++);
if (c1 != c2) {
return c1 - c2;
}
@@ -1710,8 +1710,8 @@ ZEND_API int zend_binary_strncasecmp(char *s1, uint len1, char *s2, uint len2, u
len = MIN(length, MIN(len1, len2));
while (len--) {
- c1 = tolower(*s1++);
- c2 = tolower(*s2++);
+ c1 = tolower((int)*(unsigned char *)s1++);
+ c2 = tolower((int)*(unsigned char *)s2++);
if (c1 != c2) {
return c1 - c2;
}