summaryrefslogtreecommitdiff
path: root/Zend/zend_builtin_functions.c
diff options
context:
space:
mode:
authorAnatol Belski <ab@php.net>2014-10-03 20:30:49 +0200
committerAnatol Belski <ab@php.net>2014-10-03 20:30:49 +0200
commitee4ae7fbc3ba6de5f51f95a621e14a18dd55c95d (patch)
treed774f5b506e70bc8a70ef22988e2d374bf0756b8 /Zend/zend_builtin_functions.c
parent45e23645a42ba939fb1cca9cc099f977af2a4722 (diff)
parent1ff094deb481234c0aa2fb5b0ee144b7aba924ff (diff)
downloadphp-git-ee4ae7fbc3ba6de5f51f95a621e14a18dd55c95d.tar.gz
Merge remote-tracking branch 'origin/master' into native-tls
* origin/master: remove the remains of dsp files handling fix EX usage remove misprint parentheses remove misprint parentheses Replaced EG(This) and EX(object) with EX(This). Internal functions now recieves zend_execute_data as the first argument. And this one... It should be in extern c Remove useless condition NEWS entry for previous commit NEWS entry for previous commit add IPv6 support to php-fpm Micro optimization for the most frequency case Add hash to EXTENSIONS file Remove extensions which are long gone we also have xz release tarballs since 5.5 Fix ZTS build improved file size computation in stat() Fixed incorrect compilation 5.5.19 now
Diffstat (limited to 'Zend/zend_builtin_functions.c')
-rw-r--r--Zend/zend_builtin_functions.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c
index 03a148a473..728d90acdf 100644
--- a/Zend/zend_builtin_functions.c
+++ b/Zend/zend_builtin_functions.c
@@ -400,7 +400,7 @@ ZEND_FUNCTION(gc_disable)
Get the number of arguments that were passed to the function */
ZEND_FUNCTION(func_num_args)
{
- zend_execute_data *ex = EG(current_execute_data)->prev_execute_data;
+ zend_execute_data *ex = EX(prev_execute_data);
if (ex->frame_kind == VM_FRAME_NESTED_FUNCTION || ex->frame_kind == VM_FRAME_TOP_FUNCTION) {
RETURN_LONG(ex->num_args);
@@ -429,7 +429,7 @@ ZEND_FUNCTION(func_get_arg)
RETURN_FALSE;
}
- ex = EG(current_execute_data)->prev_execute_data;
+ ex = EX(prev_execute_data);
if (ex->frame_kind != VM_FRAME_NESTED_FUNCTION && ex->frame_kind != VM_FRAME_TOP_FUNCTION) {
zend_error(E_WARNING, "func_get_arg(): Called from the global scope - no function context");
RETURN_FALSE;
@@ -462,7 +462,7 @@ ZEND_FUNCTION(func_get_args)
zval *p;
uint32_t arg_count, first_extra_arg;
uint32_t i;
- zend_execute_data *ex = EG(current_execute_data)->prev_execute_data;
+ zend_execute_data *ex = EX(prev_execute_data);
if (ex->frame_kind != VM_FRAME_NESTED_FUNCTION && ex->frame_kind != VM_FRAME_TOP_FUNCTION) {
zend_error(E_WARNING, "func_get_args(): Called from the global scope - no function context");
@@ -823,8 +823,8 @@ ZEND_FUNCTION(get_called_class)
return;
}
- if (EG(current_execute_data)->called_scope) {
- RETURN_STR(zend_string_copy(EG(current_execute_data)->called_scope->name));
+ if (EX(called_scope)) {
+ RETURN_STR(zend_string_copy(EX(called_scope)->name));
} else if (!EG(scope)) {
zend_error(E_WARNING, "get_called_class() called from outside a class");
}
@@ -2132,7 +2132,7 @@ ZEND_FUNCTION(debug_print_backtrace)
}
ZVAL_UNDEF(&arg_array);
- ptr = EG(current_execute_data)->prev_execute_data;
+ ptr = EX(prev_execute_data);
/* skip debug_backtrace() */
call = ptr;
@@ -2172,7 +2172,7 @@ ZEND_FUNCTION(debug_print_backtrace)
}
/* $this may be passed into regular internal functions */
- object = call->object;
+ object = Z_OBJ(call->This);
if (object &&
call &&
call->func->type == ZEND_INTERNAL_FUNCTION &&
@@ -2394,7 +2394,7 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int
}
/* $this may be passed into regular internal functions */
- object = call ? call->object : NULL;
+ object = call ? Z_OBJ(call->This) : NULL;
if (object &&
call->func &&
call->func->type == ZEND_INTERNAL_FUNCTION &&