From: Rolland Santimano Date: Wed, 17 Aug 2005 10:26:02 +0000 (+0000) Subject: php_u_trim_range(): Alloc UChar32 units rather than UChar X-Git-Tag: PRE_NEW_OCI8_EXTENSION~200 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c98838037e45a2926c41ccdabec139fff054f3f7;p=php php_u_trim_range(): Alloc UChar32 units rather than UChar --- diff --git a/ext/standard/string.c b/ext/standard/string.c index 376f6585ce..84f96d80ec 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -610,7 +610,7 @@ static int php_expand_u_trim_range(UChar **range, int32_t *range_len TSRMLS_DC) c = input[0]; if ( (input+3 < end) && input[1] == '.' && input[2] == '.' && input[3] >= c ) { tmp_len += (input[3] - c + 1); - tmp = (UChar32 *)erealloc(tmp, tmp_len*sizeof(UChar)); + tmp = (UChar32 *)erealloc(tmp, tmp_len*sizeof(UChar32)); for ( ; c <= input[3] ; c++ ) { if ( U_IS_UNICODE_CHAR(c) ) tmp[idx++] = c; }