summaryrefslogtreecommitdiff
path: root/ext/standard/basic_functions.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/standard/basic_functions.c')
-rw-r--r--ext/standard/basic_functions.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c
index ca8bbae35b..16077bcb5b 100644
--- a/ext/standard/basic_functions.c
+++ b/ext/standard/basic_functions.c
@@ -4265,7 +4265,7 @@ PHP_FUNCTION(getopt)
* in order to be on the safe side, even though it is also available
* from the symbol table. */
if ((Z_TYPE(PG(http_globals)[TRACK_VARS_SERVER]) == IS_ARRAY || zend_is_auto_global_str(ZEND_STRL("_SERVER"))) &&
- ((args = zend_hash_str_find_ind(HASH_OF(&PG(http_globals)[TRACK_VARS_SERVER]), "argv", sizeof("argv")-1)) != NULL ||
+ ((args = zend_hash_str_find_ind(Z_ARRVAL_P(&PG(http_globals)[TRACK_VARS_SERVER]), "argv", sizeof("argv")-1)) != NULL ||
(args = zend_hash_str_find_ind(&EG(symbol_table), "argv", sizeof("argv")-1)) != NULL)
) {
int pos = 0;
@@ -4379,23 +4379,23 @@ PHP_FUNCTION(getopt)
if (!(optname_len > 1 && optname[0] == '0') && is_numeric_string(optname, optname_len, NULL, NULL, 0) == IS_LONG) {
/* numeric string */
int optname_int = atoi(optname);
- if ((args = zend_hash_index_find(HASH_OF(return_value), optname_int)) != NULL) {
+ if ((args = zend_hash_index_find(Z_ARRVAL_P(return_value), optname_int)) != NULL) {
if (Z_TYPE_P(args) != IS_ARRAY) {
convert_to_array_ex(args);
}
- zend_hash_next_index_insert(HASH_OF(args), &val);
+ zend_hash_next_index_insert(Z_ARRVAL_P(args), &val);
} else {
- zend_hash_index_update(HASH_OF(return_value), optname_int, &val);
+ zend_hash_index_update(Z_ARRVAL_P(return_value), optname_int, &val);
}
} else {
/* other strings */
- if ((args = zend_hash_str_find(HASH_OF(return_value), optname, strlen(optname))) != NULL) {
+ if ((args = zend_hash_str_find(Z_ARRVAL_P(return_value), optname, strlen(optname))) != NULL) {
if (Z_TYPE_P(args) != IS_ARRAY) {
convert_to_array_ex(args);
}
- zend_hash_next_index_insert(HASH_OF(args), &val);
+ zend_hash_next_index_insert(Z_ARRVAL_P(args), &val);
} else {
- zend_hash_str_add(HASH_OF(return_value), optname, strlen(optname), &val);
+ zend_hash_str_add(Z_ARRVAL_P(return_value), optname, strlen(optname), &val);
}
}