diff options
author | Zeev Suraski <zeev@php.net> | 2000-12-22 12:49:51 +0000 |
---|---|---|
committer | Zeev Suraski <zeev@php.net> | 2000-12-22 12:49:51 +0000 |
commit | 36eaad252fc5fe292cd4f071f76e7879ce21130c (patch) | |
tree | 5b5f4c0f06122a3ac45c6414f3ab1d778027cc9c /Zend/zend_builtin_functions.c | |
parent | 0fcce4a77a4783bb2366d562d957da5a9249134f (diff) | |
download | php-git-36eaad252fc5fe292cd4f071f76e7879ce21130c.tar.gz |
Allow get_current_key() not to return the key itself, instead of a duplicate
Diffstat (limited to 'Zend/zend_builtin_functions.c')
-rw-r--r-- | Zend/zend_builtin_functions.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index abb9d19a88..77c09c37d8 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -332,7 +332,7 @@ ZEND_FUNCTION(each) entry->refcount++; /* add the key elements */ - switch (zend_hash_get_current_key(target_hash, &string_key, &num_key)) { + switch (zend_hash_get_current_key(target_hash, &string_key, &num_key, 1)) { case HASH_KEY_IS_STRING: add_get_index_string(return_value,0,string_key,(void **) &inserted_pointer,0); break; @@ -589,7 +589,7 @@ ZEND_FUNCTION(get_class_methods) efree(lcname); array_init(return_value); zend_hash_internal_pointer_reset(&ce->function_table); - while ((key_type = zend_hash_get_current_key(&ce->function_table, &string_key, &num_key)) != HASH_KEY_NON_EXISTANT) { + while ((key_type = zend_hash_get_current_key(&ce->function_table, &string_key, &num_key, 1)) != HASH_KEY_NON_EXISTANT) { if (key_type == HASH_KEY_IS_STRING) { MAKE_STD_ZVAL(method_name); ZVAL_STRING(method_name, string_key, 0); @@ -731,7 +731,7 @@ ZEND_FUNCTION(get_included_files) array_init(return_value); zend_hash_internal_pointer_reset(&EG(included_files)); - while(zend_hash_get_current_key(&EG(included_files), &entry,NULL) == HASH_KEY_IS_STRING) { + while(zend_hash_get_current_key(&EG(included_files), &entry, NULL, 1) == HASH_KEY_IS_STRING) { add_next_index_string(return_value,entry,0); zend_hash_move_forward(&EG(included_files)); } |