summaryrefslogtreecommitdiff
path: root/ext/pcre/php_pcre.c
diff options
context:
space:
mode:
authorZeev Suraski <zeev@php.net>2000-12-22 12:57:09 +0000
committerZeev Suraski <zeev@php.net>2000-12-22 12:57:09 +0000
commitaa6d2ac5d0ee1d7cd608c6930ad0c57bc2953c47 (patch)
tree5776ae30d4c8115659935309042b9784ba55d592 /ext/pcre/php_pcre.c
parent36eaad252fc5fe292cd4f071f76e7879ce21130c (diff)
downloadphp-git-aa6d2ac5d0ee1d7cd608c6930ad0c57bc2953c47.tar.gz
Heads up people!
Updated the get_current_key() API - the relevant authors, please take a look at the updated code and make sure it's ok...
Diffstat (limited to 'ext/pcre/php_pcre.c')
-rw-r--r--ext/pcre/php_pcre.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c
index 9c39bf8324..e4480d468c 100644
--- a/ext/pcre/php_pcre.c
+++ b/ext/pcre/php_pcre.c
@@ -1017,11 +1017,10 @@ PHP_FUNCTION(preg_replace)
(void **)&subject_entry) == SUCCESS) {
if ((result = php_replace_in_subject(*regex, *replace, subject_entry, &result_len, limit_val)) != NULL) {
/* Add to return array */
- switch(zend_hash_get_current_key((*subject)->value.ht, &string_key, &num_key))
+ switch(zend_hash_get_current_key((*subject)->value.ht, &string_key, &num_key, 0))
{
case HASH_KEY_IS_STRING:
add_assoc_stringl(return_value, string_key, result, result_len, 0);
- efree(string_key);
break;
case HASH_KEY_IS_LONG:
@@ -1314,12 +1313,11 @@ PHP_FUNCTION(preg_grep)
(*entry)->refcount++;
/* Add to return array */
- switch(zend_hash_get_current_key((*input)->value.ht, &string_key, &num_key))
+ switch(zend_hash_get_current_key((*input)->value.ht, &string_key, &num_key, 0))
{
case HASH_KEY_IS_STRING:
zend_hash_update(return_value->value.ht, string_key,
strlen(string_key)+1, entry, sizeof(zval *), NULL);
- efree(string_key);
break;
case HASH_KEY_IS_LONG: