From: Antony Dovgal Date: Fri, 12 Aug 2005 16:46:38 +0000 (+0000) Subject: fix php_u_trim() and compile warnings X-Git-Tag: PRE_NEW_OCI8_EXTENSION~304 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=079a748d3c44264f000aef4a9d0f941c4acdb49a;p=php fix php_u_trim() and compile warnings --- diff --git a/ext/standard/string.c b/ext/standard/string.c index 96eedb6fc7..1b9cff5398 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -718,12 +718,12 @@ static UChar *php_u_trim(UChar *c, int32_t len, UChar *what, int32_t what_len, z } } else { /* Trimmed the whole string */ if ( return_value ) { - RETURN_EMPTY_UNICODE(); + RETVAL_EMPTY_UNICODE(); } else { return (USTR_MAKE("")); } } - + return (USTR_MAKE("")); } /* }}} */ @@ -1911,7 +1911,7 @@ PHP_FUNCTION(strstr) case IS_UNICODE: found_offset = (UChar*)found - (UChar*)haystack; if (part) { - char *ret; + UChar *ret; ret = eumalloc(found_offset + 1); u_strncpy(ret, haystack, found_offset); ret[found_offset] = '\0';