Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/Zend/zend.h b/Zend/zend.h
- index e886ba2..8c3c81e 100644
- --- a/Zend/zend.h
- +++ b/Zend/zend.h
- @@ -331,6 +331,7 @@ ZEND_API void zend_restore_error_handling(zend_error_handling *saved);
- #define DEBUG_BACKTRACE_PROVIDE_OBJECT (1<<0)
- #define DEBUG_BACKTRACE_IGNORE_ARGS (1<<1)
- +#define DEBUG_BACKTRACE_PROVIDE_CALLED (1<<2)
- #include "zend_object_handlers.h"
- #include "zend_operators.h"
- diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c
- index 0cbafc7..5eb6d29 100644
- --- a/Zend/zend_builtin_functions.c
- +++ b/Zend/zend_builtin_functions.c
- @@ -2672,9 +2672,11 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int
- if (object) {
- if (func->common.scope) {
- add_assoc_str_ex(&stack_frame, "class", sizeof("class")-1, zend_string_copy(func->common.scope->name));
- + if ((options & DEBUG_BACKTRACE_PROVIDE_CALLED) != 0) {
- + add_assoc_str_ex(&stack_frame, "called", sizeof("called")-1, zend_string_copy(object->ce->name));
- + }
- } else {
- add_assoc_str_ex(&stack_frame, "class", sizeof("class")-1, zend_string_copy(object->ce->name));
- -
- }
- if ((options & DEBUG_BACKTRACE_PROVIDE_OBJECT) != 0) {
- zval zv;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement