mirror of
https://github.com/php/php-src.git
synced 2026-04-05 07:02:33 +02:00
- MF44: Problems with user defined error handler and references
This commit is contained in:
@@ -1376,10 +1376,10 @@ ZEND_VM_HANDLER(39, ZEND_ASSIGN_REF, VAR|CV, VAR|CV)
|
||||
!(*value_ptr_ptr)->is_ref &&
|
||||
opline->extended_value == ZEND_RETURNS_FUNCTION &&
|
||||
!EX_T(opline->op2.u.var).var.fcall_returned_reference) {
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
if (free_op2.var == NULL) {
|
||||
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
|
||||
}
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
ZEND_VM_DISPATCH_TO_HANDLER(ZEND_ASSIGN);
|
||||
}
|
||||
|
||||
|
||||
@@ -11674,10 +11674,10 @@ static int ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
!(*value_ptr_ptr)->is_ref &&
|
||||
opline->extended_value == ZEND_RETURNS_FUNCTION &&
|
||||
!EX_T(opline->op2.u.var).var.fcall_returned_reference) {
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
if (free_op2.var == NULL) {
|
||||
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
|
||||
}
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
return ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
@@ -13500,10 +13500,10 @@ static int ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
!(*value_ptr_ptr)->is_ref &&
|
||||
opline->extended_value == ZEND_RETURNS_FUNCTION &&
|
||||
!EX_T(opline->op2.u.var).var.fcall_returned_reference) {
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
if (free_op2.var == NULL) {
|
||||
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
|
||||
}
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
return ZEND_ASSIGN_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
@@ -23590,10 +23590,10 @@ static int ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
!(*value_ptr_ptr)->is_ref &&
|
||||
opline->extended_value == ZEND_RETURNS_FUNCTION &&
|
||||
!EX_T(opline->op2.u.var).var.fcall_returned_reference) {
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
if (free_op2.var == NULL) {
|
||||
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
|
||||
}
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
return ZEND_ASSIGN_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
@@ -25416,10 +25416,10 @@ static int ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
!(*value_ptr_ptr)->is_ref &&
|
||||
opline->extended_value == ZEND_RETURNS_FUNCTION &&
|
||||
!EX_T(opline->op2.u.var).var.fcall_returned_reference) {
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
if (free_op2.var == NULL) {
|
||||
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
|
||||
}
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
return ZEND_ASSIGN_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
@@ -31054,10 +31054,10 @@ static int ZEND_ASSIGN_REF_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
!(*value_ptr_ptr)->is_ref &&
|
||||
opline->extended_value == ZEND_RETURNS_FUNCTION &&
|
||||
!EX_T(opline->op2.u.var).var.fcall_returned_reference) {
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
if (free_op2.var == NULL) {
|
||||
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
|
||||
}
|
||||
zend_error(E_STRICT, "Only variables should be assigned by reference");
|
||||
return ZEND_ASSIGN_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user