diff options
| author | Marcus Boerger <helly@php.net> | 2003-05-21 21:59:40 +0000 |
|---|---|---|
| committer | Marcus Boerger <helly@php.net> | 2003-05-21 21:59:40 +0000 |
| commit | 7af8eadd57b198c7fc91698cdfe68300d3aeec19 (patch) | |
| tree | 83a864335a1c61be756464bca9ae1bc6238c8cfd /Zend/zend_execute_API.c | |
| parent | bbe87059fb660fa771c0a6d323eb3a0ee06ca0e7 (diff) | |
| download | php-git-7af8eadd57b198c7fc91698cdfe68300d3aeec19.tar.gz | |
Make zend_str_tolower_copy() a copy function (like stccpy).
Supply a dup version (like estrdup).
Fix tolower() handling.
# Havin copy and dup allows to use the faster version even with
# memory not allocated by emalloc.
Diffstat (limited to 'Zend/zend_execute_API.c')
| -rw-r--r-- | Zend/zend_execute_API.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 3d04fe7747..3a001eee1c 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -595,7 +595,7 @@ int fast_call_user_function(HashTable *function_table, zval **object_pp, zval *f char *lc_class; int found; - lc_class = zend_str_tolower_copy(Z_STRVAL_PP(object_pp), Z_STRLEN_PP(object_pp)); + lc_class = zend_str_tolower_dup(Z_STRVAL_PP(object_pp), Z_STRLEN_PP(object_pp)); found = zend_lookup_class(lc_class, Z_STRLEN_PP(object_pp), &ce TSRMLS_CC); efree(lc_class); if (found == FAILURE) @@ -612,7 +612,7 @@ int fast_call_user_function(HashTable *function_table, zval **object_pp, zval *f return FAILURE; } - function_name_lc = zend_str_tolower_copy(function_name->value.str.val, function_name->value.str.len); + function_name_lc = zend_str_tolower_dup(function_name->value.str.val, function_name->value.str.len); original_function_state_ptr = EG(function_state_ptr); if (zend_hash_find(function_table, function_name_lc, function_name->value.str.len+1, (void **) &EX(function_state).function)==FAILURE) { |
