diff options
author | Dmitry Stogov <dmitry@zend.com> | 2013-04-23 23:55:47 +0400 |
---|---|---|
committer | Dmitry Stogov <dmitry@zend.com> | 2013-04-23 23:55:47 +0400 |
commit | 43ab915b41bbb236ca0aa1966c946c9c36fa2a2b (patch) | |
tree | 65a9c2836d3e70043ad1df312d13e3e64f23a8d3 | |
parent | b3aa3c26168df33fd739669bb7ede2af88051158 (diff) | |
parent | 4cf0647399b7f79fa1d74bba9d528bc74b78ba10 (diff) | |
download | php-git-43ab915b41bbb236ca0aa1966c946c9c36fa2a2b.tar.gz |
Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
Fixed incorrect check. SEND_REF may be executed before DO_FCALL when EX(function_state).function is not yet set to the calling function.
Conflicts:
Zend/zend_vm_def.h
Zend/zend_vm_execute.h
-rw-r--r-- | Zend/zend_vm_def.h | 4 | ||||
-rw-r--r-- | Zend/zend_vm_execute.h | 8 |
2 files changed, 9 insertions, 3 deletions
diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index f051c1a588..eed65e3e27 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -3140,7 +3140,9 @@ ZEND_VM_HANDLER(67, ZEND_SEND_REF, VAR|CV, ANY) 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); } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 07082d44ff..18b3f4772c 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -11171,7 +11171,9 @@ static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG 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)) { return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } @@ -27123,7 +27125,9 @@ static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS 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)) { return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } |