version 1.1.1.2, 2012/05/29 12:34:36
|
version 1.1.1.5, 2014/06/15 20:04:04
|
Line 2
|
Line 2
|
+----------------------------------------------------------------------+ |
+----------------------------------------------------------------------+ |
| Zend Engine | |
| Zend Engine | |
+----------------------------------------------------------------------+ |
+----------------------------------------------------------------------+ |
| Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | | | Copyright (c) 1998-2014 Zend Technologies Ltd. (http://www.zend.com) | |
+----------------------------------------------------------------------+ |
+----------------------------------------------------------------------+ |
| This source file is subject to version 2.00 of the Zend license, | |
| This source file is subject to version 2.00 of the Zend license, | |
| that is bundled with this package in the file LICENSE, and is | |
| that is bundled with this package in the file LICENSE, and is | |
Line 974 ZEND_VM_HANDLER(40, ZEND_ECHO, CONST|TMP|VAR|CV, ANY)
|
Line 974 ZEND_VM_HANDLER(40, ZEND_ECHO, CONST|TMP|VAR|CV, ANY)
|
{ |
{ |
USE_OPLINE |
USE_OPLINE |
zend_free_op free_op1; |
zend_free_op free_op1; |
zval z_copy; |
|
zval *z; |
zval *z; |
|
|
SAVE_OPLINE(); |
SAVE_OPLINE(); |
z = GET_OP1_ZVAL_PTR(BP_VAR_R); |
z = GET_OP1_ZVAL_PTR(BP_VAR_R); |
|
|
if (OP1_TYPE != IS_CONST && | if (OP1_TYPE == IS_TMP_VAR && Z_TYPE_P(z) == IS_OBJECT) { |
UNEXPECTED(Z_TYPE_P(z) == IS_OBJECT) && | INIT_PZVAL(z); |
Z_OBJ_HT_P(z)->get_method != NULL) { | |
if (OP1_TYPE == IS_TMP_VAR) { | |
INIT_PZVAL(z); | |
} | |
if (zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { | |
zend_print_variable(&z_copy); | |
zval_dtor(&z_copy); | |
} else { | |
zend_print_variable(z); | |
} | |
} else { | |
zend_print_variable(z); | |
} |
} |
|
zend_print_variable(z); |
|
|
FREE_OP1(); |
FREE_OP1(); |
CHECK_EXCEPTION(); |
CHECK_EXCEPTION(); |
Line 1178 ZEND_VM_HANDLER(81, ZEND_FETCH_DIM_R, VAR|CV, CONST|TM
|
Line 1166 ZEND_VM_HANDLER(81, ZEND_FETCH_DIM_R, VAR|CV, CONST|TM
|
{ |
{ |
USE_OPLINE |
USE_OPLINE |
zend_free_op free_op1, free_op2; |
zend_free_op free_op1, free_op2; |
zval **container; | zval *container; |
|
|
SAVE_OPLINE(); |
SAVE_OPLINE(); |
|
|
if ((opline->extended_value & ZEND_FETCH_ADD_LOCK) && | if (OP1_TYPE == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { |
OP1_TYPE != IS_CV && | PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); |
EX_T(opline->op1.var).var.ptr_ptr) { | |
PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); | |
} |
} |
container = GET_OP1_ZVAL_PTR_PTR(BP_VAR_R); | container = GET_OP1_ZVAL_PTR(BP_VAR_R); |
zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, GET_OP2_ZVAL_PTR(BP_VAR_R), OP2_TYPE, BP_VAR_R TSRMLS_CC); |
zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, GET_OP2_ZVAL_PTR(BP_VAR_R), OP2_TYPE, BP_VAR_R TSRMLS_CC); |
FREE_OP2(); |
FREE_OP2(); |
FREE_OP1_VAR_PTR(); | FREE_OP1(); |
CHECK_EXCEPTION(); |
CHECK_EXCEPTION(); |
ZEND_VM_NEXT_OPCODE(); |
ZEND_VM_NEXT_OPCODE(); |
} |
} |
Line 1255 ZEND_VM_HANDLER(90, ZEND_FETCH_DIM_IS, VAR|CV, CONST|T
|
Line 1241 ZEND_VM_HANDLER(90, ZEND_FETCH_DIM_IS, VAR|CV, CONST|T
|
{ |
{ |
USE_OPLINE |
USE_OPLINE |
zend_free_op free_op1, free_op2; |
zend_free_op free_op1, free_op2; |
zval **container; | zval *container; |
|
|
SAVE_OPLINE(); |
SAVE_OPLINE(); |
container = GET_OP1_ZVAL_PTR_PTR(BP_VAR_IS); | container = GET_OP1_ZVAL_PTR(BP_VAR_IS); |
zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, GET_OP2_ZVAL_PTR(BP_VAR_R), OP2_TYPE, BP_VAR_IS TSRMLS_CC); |
zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, GET_OP2_ZVAL_PTR(BP_VAR_R), OP2_TYPE, BP_VAR_IS TSRMLS_CC); |
FREE_OP2(); |
FREE_OP2(); |
FREE_OP1_VAR_PTR(); | FREE_OP1(); |
CHECK_EXCEPTION(); |
CHECK_EXCEPTION(); |
ZEND_VM_NEXT_OPCODE(); |
ZEND_VM_NEXT_OPCODE(); |
} |
} |
Line 1270 ZEND_VM_HANDLER(93, ZEND_FETCH_DIM_FUNC_ARG, VAR|CV, C
|
Line 1256 ZEND_VM_HANDLER(93, ZEND_FETCH_DIM_FUNC_ARG, VAR|CV, C
|
{ |
{ |
USE_OPLINE |
USE_OPLINE |
zend_free_op free_op1, free_op2; |
zend_free_op free_op1, free_op2; |
zval **container; |
|
|
|
SAVE_OPLINE(); |
SAVE_OPLINE(); |
|
|
if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { |
if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { |
container = GET_OP1_ZVAL_PTR_PTR(BP_VAR_W); | zval **container = GET_OP1_ZVAL_PTR_PTR(BP_VAR_W); |
| |
if (OP1_TYPE == IS_VAR && UNEXPECTED(container == NULL)) { |
if (OP1_TYPE == IS_VAR && UNEXPECTED(container == NULL)) { |
zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); |
zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); |
} |
} |
Line 1283 ZEND_VM_HANDLER(93, ZEND_FETCH_DIM_FUNC_ARG, VAR|CV, C
|
Line 1269 ZEND_VM_HANDLER(93, ZEND_FETCH_DIM_FUNC_ARG, VAR|CV, C
|
if (OP1_TYPE == IS_VAR && OP1_FREE && READY_TO_DESTROY(free_op1.var)) { |
if (OP1_TYPE == IS_VAR && OP1_FREE && READY_TO_DESTROY(free_op1.var)) { |
EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); |
EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); |
} |
} |
|
FREE_OP2(); |
|
FREE_OP1_VAR_PTR(); |
} else { |
} else { |
|
zval *container; |
|
|
if (OP2_TYPE == IS_UNUSED) { |
if (OP2_TYPE == IS_UNUSED) { |
zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); |
zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); |
} |
} |
container = GET_OP1_ZVAL_PTR_PTR(BP_VAR_R); | container = GET_OP1_ZVAL_PTR(BP_VAR_R); |
zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, GET_OP2_ZVAL_PTR(BP_VAR_R), OP2_TYPE, BP_VAR_R TSRMLS_CC); |
zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, GET_OP2_ZVAL_PTR(BP_VAR_R), OP2_TYPE, BP_VAR_R TSRMLS_CC); |
|
FREE_OP2(); |
|
FREE_OP1(); |
} |
} |
FREE_OP2(); |
|
FREE_OP1_VAR_PTR(); |
|
CHECK_EXCEPTION(); |
CHECK_EXCEPTION(); |
ZEND_VM_NEXT_OPCODE(); |
ZEND_VM_NEXT_OPCODE(); |
} |
} |
Line 2241 ZEND_VM_HANDLER(113, ZEND_INIT_STATIC_METHOD_CALL, CON
|
Line 2231 ZEND_VM_HANDLER(113, ZEND_INIT_STATIC_METHOD_CALL, CON
|
ce = CACHED_PTR(opline->op1.literal->cache_slot); |
ce = CACHED_PTR(opline->op1.literal->cache_slot); |
} else { |
} else { |
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC); |
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC); |
|
if (UNEXPECTED(EG(exception) != NULL)) { |
|
HANDLE_EXCEPTION(); |
|
} |
if (UNEXPECTED(ce == NULL)) { |
if (UNEXPECTED(ce == NULL)) { |
CHECK_EXCEPTION(); | zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv)); |
ZEND_VM_NEXT_OPCODE(); | |
} |
} |
CACHE_PTR(opline->op1.literal->cache_slot, ce); |
CACHE_PTR(opline->op1.literal->cache_slot, ce); |
} |
} |
Line 2412 ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONS
|
Line 2404 ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONS
|
zend_hash_index_find(Z_ARRVAL_P(function_name), 0, (void **) &obj); |
zend_hash_index_find(Z_ARRVAL_P(function_name), 0, (void **) &obj); |
zend_hash_index_find(Z_ARRVAL_P(function_name), 1, (void **) &method); |
zend_hash_index_find(Z_ARRVAL_P(function_name), 1, (void **) &method); |
|
|
|
if (!obj || !method) { |
|
zend_error_noreturn(E_ERROR, "Array callback has to contain indices 0 and 1"); |
|
} |
|
|
if (Z_TYPE_PP(obj) != IS_STRING && Z_TYPE_PP(obj) != IS_OBJECT) { |
if (Z_TYPE_PP(obj) != IS_STRING && Z_TYPE_PP(obj) != IS_OBJECT) { |
zend_error_noreturn(E_ERROR, "First array member is not a valid class name or object"); |
zend_error_noreturn(E_ERROR, "First array member is not a valid class name or object"); |
} |
} |
Line 2422 ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONS
|
Line 2418 ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONS
|
|
|
if (Z_TYPE_PP(obj) == IS_STRING) { |
if (Z_TYPE_PP(obj) == IS_STRING) { |
ce = zend_fetch_class_by_name(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), NULL, 0 TSRMLS_CC); |
ce = zend_fetch_class_by_name(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), NULL, 0 TSRMLS_CC); |
|
if (UNEXPECTED(EG(exception) != NULL)) { |
|
HANDLE_EXCEPTION(); |
|
} |
if (UNEXPECTED(ce == NULL)) { |
if (UNEXPECTED(ce == NULL)) { |
CHECK_EXCEPTION(); | zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_PP(obj)); |
ZEND_VM_NEXT_OPCODE(); | |
} |
} |
EX(called_scope) = ce; |
EX(called_scope) = ce; |
EX(object) = NULL; |
EX(object) = NULL; |
Line 2442 ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONS
|
Line 2440 ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONS
|
if (UNEXPECTED(EX(fbc) == NULL)) { |
if (UNEXPECTED(EX(fbc) == NULL)) { |
zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); |
zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); |
} |
} |
| |
if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { |
if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { |
EX(object) = NULL; |
EX(object) = NULL; |
} else { |
} else { |
Line 2665 ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY)
|
Line 2663 ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY)
|
if (fbc->type == ZEND_INTERNAL_FUNCTION) { |
if (fbc->type == ZEND_INTERNAL_FUNCTION) { |
temp_variable *ret = &EX_T(opline->result.var); |
temp_variable *ret = &EX_T(opline->result.var); |
|
|
MAKE_STD_ZVAL(ret->var.ptr); |
|
ZVAL_NULL(ret->var.ptr); |
|
ret->var.ptr_ptr = &ret->var.ptr; |
|
ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; |
|
|
|
if (fbc->common.arg_info) { |
if (fbc->common.arg_info) { |
zend_uint i=0; |
zend_uint i=0; |
zval **p = (zval**)EX(function_state).arguments; |
zval **p = (zval**)EX(function_state).arguments; |
Line 2681 ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY)
|
Line 2674 ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY)
|
} |
} |
} |
} |
|
|
if (!zend_execute_internal) { | if (EXPECTED(EG(exception) == NULL)) { |
/* saves one function call if zend_execute_internal is not used */ | MAKE_STD_ZVAL(ret->var.ptr); |
fbc->internal_function.handler(opline->extended_value, ret->var.ptr, (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) ? &ret->var.ptr : NULL, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); | ZVAL_NULL(ret->var.ptr); |
} else { | ret->var.ptr_ptr = &ret->var.ptr; |
zend_execute_internal(EXECUTE_DATA, RETURN_VALUE_USED(opline) TSRMLS_CC); | ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; |
} | |
|
|
if (!RETURN_VALUE_USED(opline)) { | if (!zend_execute_internal) { |
zval_ptr_dtor(&ret->var.ptr); | /* saves one function call if zend_execute_internal is not used */ |
| fbc->internal_function.handler(opline->extended_value, ret->var.ptr, (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) ? &ret->var.ptr : NULL, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); |
| } else { |
| zend_execute_internal(EXECUTE_DATA, RETURN_VALUE_USED(opline) TSRMLS_CC); |
| } |
| |
| if (!RETURN_VALUE_USED(opline)) { |
| zval_ptr_dtor(&ret->var.ptr); |
| } |
| } else if (RETURN_VALUE_USED(opline)) { |
| EX_T(opline->result.var).var.ptr = NULL; |
} |
} |
} else if (fbc->type == ZEND_USER_FUNCTION) { |
} else if (fbc->type == ZEND_USER_FUNCTION) { |
EX(original_return_value) = EG(return_value_ptr_ptr); |
EX(original_return_value) = EG(return_value_ptr_ptr); |
Line 2910 ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR
|
Line 2912 ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR
|
} else if (EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { |
} else if (EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { |
zend_error(E_NOTICE, "Only variable references should be returned by reference"); |
zend_error(E_NOTICE, "Only variable references should be returned by reference"); |
if (EG(return_value_ptr_ptr)) { |
if (EG(return_value_ptr_ptr)) { |
retval_ptr = *retval_ptr_ptr; | zval *ret; |
*EG(return_value_ptr_ptr) = retval_ptr; | |
Z_ADDREF_P(retval_ptr); | ALLOC_ZVAL(ret); |
| INIT_PZVAL_COPY(ret, *retval_ptr_ptr); |
| zval_copy_ctor(ret); |
| *EG(return_value_ptr_ptr) = ret; |
} |
} |
break; |
break; |
} |
} |
Line 2974 ZEND_VM_HANDLER(107, ZEND_CATCH, CONST, CV)
|
Line 2979 ZEND_VM_HANDLER(107, ZEND_CATCH, CONST, CV)
|
catch_ce = CACHED_PTR(opline->op1.literal->cache_slot); |
catch_ce = CACHED_PTR(opline->op1.literal->cache_slot); |
} else { |
} else { |
catch_ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, ZEND_FETCH_CLASS_NO_AUTOLOAD TSRMLS_CC); |
catch_ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, ZEND_FETCH_CLASS_NO_AUTOLOAD TSRMLS_CC); |
| |
CACHE_PTR(opline->op1.literal->cache_slot, catch_ce); |
CACHE_PTR(opline->op1.literal->cache_slot, catch_ce); |
} |
} |
ce = Z_OBJCE_P(EG(exception)); |
ce = Z_OBJCE_P(EG(exception)); |
|
|
#ifdef HAVE_DTRACE |
#ifdef HAVE_DTRACE |
if (DTRACE_EXCEPTION_CAUGHT_ENABLED()) { |
if (DTRACE_EXCEPTION_CAUGHT_ENABLED()) { |
DTRACE_EXCEPTION_CAUGHT(ce->name); | DTRACE_EXCEPTION_CAUGHT((char *)ce->name); |
} |
} |
#endif /* HAVE_DTRACE */ |
#endif /* HAVE_DTRACE */ |
|
|
Line 3146 ZEND_VM_HANDLER(67, ZEND_SEND_REF, VAR|CV, ANY)
|
Line 3151 ZEND_VM_HANDLER(67, ZEND_SEND_REF, VAR|CV, ANY)
|
ZEND_VM_NEXT_OPCODE(); |
ZEND_VM_NEXT_OPCODE(); |
} |
} |
|
|
if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { | if (opline->extended_value == ZEND_DO_FCALL_BY_NAME && |
| EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && |
| !ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { |
ZEND_VM_DISPATCH_TO_HELPER(zend_send_by_var_helper); |
ZEND_VM_DISPATCH_TO_HELPER(zend_send_by_var_helper); |
} |
} |
|
|
Line 3240 ZEND_VM_HANDLER(64, ZEND_RECV_INIT, ANY, CONST)
|
Line 3247 ZEND_VM_HANDLER(64, ZEND_RECV_INIT, ANY, CONST)
|
|
|
zend_verify_arg_type((zend_function *) EG(active_op_array), arg_num, assignment_value, opline->extended_value TSRMLS_CC); |
zend_verify_arg_type((zend_function *) EG(active_op_array), arg_num, assignment_value, opline->extended_value TSRMLS_CC); |
var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->result.var TSRMLS_CC); |
var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->result.var TSRMLS_CC); |
Z_DELREF_PP(var_ptr); | zval_ptr_dtor(var_ptr); |
*var_ptr = assignment_value; |
*var_ptr = assignment_value; |
|
|
CHECK_EXCEPTION(); |
CHECK_EXCEPTION(); |
Line 3270 ZEND_VM_HANDLER(50, ZEND_BRK, ANY, CONST)
|
Line 3277 ZEND_VM_HANDLER(50, ZEND_BRK, ANY, CONST)
|
SAVE_OPLINE(); |
SAVE_OPLINE(); |
el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, |
el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, |
EX(op_array), EX_Ts() TSRMLS_CC); |
EX(op_array), EX_Ts() TSRMLS_CC); |
FREE_OP2(); |
|
ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); |
ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); |
} |
} |
|
|
Line 3282 ZEND_VM_HANDLER(51, ZEND_CONT, ANY, CONST)
|
Line 3288 ZEND_VM_HANDLER(51, ZEND_CONT, ANY, CONST)
|
SAVE_OPLINE(); |
SAVE_OPLINE(); |
el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, |
el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, |
EX(op_array), EX_Ts() TSRMLS_CC); |
EX(op_array), EX_Ts() TSRMLS_CC); |
FREE_OP2(); |
|
ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); |
ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); |
} |
} |
|
|
Line 3426 ZEND_VM_HANDLER(110, ZEND_CLONE, CONST|TMP|VAR|UNUSED|
|
Line 3431 ZEND_VM_HANDLER(110, ZEND_CLONE, CONST|TMP|VAR|UNUSED|
|
} else if ((clone->common.fn_flags & ZEND_ACC_PROTECTED)) { |
} else if ((clone->common.fn_flags & ZEND_ACC_PROTECTED)) { |
/* Ensure that if we're calling a protected function, we're allowed to do so. |
/* Ensure that if we're calling a protected function, we're allowed to do so. |
*/ |
*/ |
if (UNEXPECTED(!zend_check_protected(clone->common.scope, EG(scope)))) { | if (UNEXPECTED(!zend_check_protected(zend_get_function_root_class(clone), EG(scope)))) { |
zend_error_noreturn(E_ERROR, "Call to protected %s::__clone() from context '%s'", ce->name, EG(scope) ? EG(scope)->name : ""); |
zend_error_noreturn(E_ERROR, "Call to protected %s::__clone() from context '%s'", ce->name, EG(scope) ? EG(scope)->name : ""); |
} |
} |
} |
} |
Line 3502 ZEND_VM_HANDLER(99, ZEND_FETCH_CONSTANT, VAR|CONST|UNU
|
Line 3507 ZEND_VM_HANDLER(99, ZEND_FETCH_CONSTANT, VAR|CONST|UNU
|
ce = CACHED_PTR(opline->op1.literal->cache_slot); |
ce = CACHED_PTR(opline->op1.literal->cache_slot); |
} else { |
} else { |
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC); |
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC); |
|
if (UNEXPECTED(EG(exception) != NULL)) { |
|
HANDLE_EXCEPTION(); |
|
} |
if (UNEXPECTED(ce == NULL)) { |
if (UNEXPECTED(ce == NULL)) { |
CHECK_EXCEPTION(); | zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv)); |
ZEND_VM_NEXT_OPCODE(); | |
} |
} |
CACHE_PTR(opline->op1.literal->cache_slot, ce); |
CACHE_PTR(opline->op1.literal->cache_slot, ce); |
} |
} |
Line 3891 ZEND_VM_HANDLER(74, ZEND_UNSET_VAR, CONST|TMP|VAR|CV,
|
Line 3898 ZEND_VM_HANDLER(74, ZEND_UNSET_VAR, CONST|TMP|VAR|CV,
|
ce = CACHED_PTR(opline->op2.literal->cache_slot); |
ce = CACHED_PTR(opline->op2.literal->cache_slot); |
} else { |
} else { |
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC); |
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC); |
if (UNEXPECTED(ce == NULL)) { | if (UNEXPECTED(EG(exception) != NULL)) { |
if (OP1_TYPE != IS_CONST && varname == &tmp) { |
if (OP1_TYPE != IS_CONST && varname == &tmp) { |
zval_dtor(&tmp); |
zval_dtor(&tmp); |
} else if (OP1_TYPE == IS_VAR || OP1_TYPE == IS_CV) { |
} else if (OP1_TYPE == IS_VAR || OP1_TYPE == IS_CV) { |
zval_ptr_dtor(&varname); |
zval_ptr_dtor(&varname); |
} |
} |
FREE_OP1(); |
FREE_OP1(); |
CHECK_EXCEPTION(); | HANDLE_EXCEPTION(); |
ZEND_VM_NEXT_OPCODE(); | |
} |
} |
|
if (UNEXPECTED(ce == NULL)) { |
|
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv)); |
|
} |
CACHE_PTR(opline->op2.literal->cache_slot, ce); |
CACHE_PTR(opline->op2.literal->cache_slot, ce); |
} |
} |
} else { |
} else { |
Line 3947 ZEND_VM_HANDLER(75, ZEND_UNSET_DIM, VAR|UNUSED|CV, CON
|
Line 3956 ZEND_VM_HANDLER(75, ZEND_UNSET_DIM, VAR|UNUSED|CV, CON
|
switch (Z_TYPE_P(offset)) { |
switch (Z_TYPE_P(offset)) { |
case IS_DOUBLE: |
case IS_DOUBLE: |
hval = zend_dval_to_lval(Z_DVAL_P(offset)); |
hval = zend_dval_to_lval(Z_DVAL_P(offset)); |
ZEND_VM_C_GOTO(num_index_dim); | zend_hash_index_del(ht, hval); |
| break; |
case IS_RESOURCE: |
case IS_RESOURCE: |
case IS_BOOL: |
case IS_BOOL: |
case IS_LONG: |
case IS_LONG: |
Line 4930 ZEND_VM_HANDLER(144, ZEND_ADD_INTERFACE, ANY, CONST)
|
Line 4940 ZEND_VM_HANDLER(144, ZEND_ADD_INTERFACE, ANY, CONST)
|
CHECK_EXCEPTION(); |
CHECK_EXCEPTION(); |
ZEND_VM_NEXT_OPCODE(); |
ZEND_VM_NEXT_OPCODE(); |
} |
} |
CACHE_PTR(opline->op2.literal->cache_slot, ce); | CACHE_PTR(opline->op2.literal->cache_slot, iface); |
} |
} |
|
|
if (UNEXPECTED((iface->ce_flags & ZEND_ACC_INTERFACE) == 0)) { |
if (UNEXPECTED((iface->ce_flags & ZEND_ACC_INTERFACE) == 0)) { |