cvs: ZendEngine2(PHP_5_3) / zend_vm_def.h zend_vm_execute.h /tests bug45805.phpt
"Dmitry Stogov" <[email protected]>
| Newsgroups | gmane.comp.php.cvs.zend |
|---|---|
| Message-ID | <cvsdmitry1218612096@cvsserver> |
dmitry Wed Aug 13 07:21:36 2008 UTC
Added files: (Branch: PHP_5_3)
/ZendEngine2/tests bug45805.phpt
Modified files:
/ZendEngine2 zend_vm_def.h zend_vm_execute.h
Log:
Fixed bug #45805 (Crach on throwing exception from error handler)
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_vm_def.h?r1=1.59.2.29.2.48.2.66&r2=1.59.2.29.2.48.2.67&diff_format=u
Index: ZendEngine2/zend_vm_def.h
diff -u ZendEngine2/zend_vm_def.h:1.59.2.29.2.48.2.66 ZendEngine2/zend_vm_def.h:1.59.2.29.2.48.2.67
--- ZendEngine2/zend_vm_def.h:1.59.2.29.2.48.2.66 Fri Aug 8 17:47:30 2008
+++ ZendEngine2/zend_vm_def.h Wed Aug 13 07:21:23 2008
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_vm_def.h,v 1.59.2.29.2.48.2.66 2008/08/08 17:47:30 helly Exp $ */
+/* $Id: zend_vm_def.h,v 1.59.2.29.2.48.2.67 2008/08/13 07:21:23 dmitry Exp $ */
/* If you change this file, please regenerate the zend_vm_execute.h and
* zend_vm_opcodes.h files by running:
@@ -1623,6 +1623,10 @@
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
}
zend_error(E_STRICT, "Only variables should be assigned by reference");
+ if (UNEXPECTED(EG(exception) != NULL)) {
+ FREE_OP2_VAR_PTR();
+ ZEND_VM_NEXT_OPCODE();
+ }
ZEND_VM_DISPATCH_TO_HANDLER(ZEND_ASSIGN);
} else if (OP2_TYPE == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) {
PZVAL_LOCK(*value_ptr_ptr);
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_vm_execute.h?r1=1.62.2.30.2.49.2.66&r2=1.62.2.30.2.49.2.67&diff_format=u
Index: ZendEngine2/zend_vm_execute.h
diff -u ZendEngine2/zend_vm_execute.h:1.62.2.30.2.49.2.66 ZendEngine2/zend_vm_execute.h:1.62.2.30.2.49.2.67
--- ZendEngine2/zend_vm_execute.h:1.62.2.30.2.49.2.66 Fri Aug 8 17:47:31 2008
+++ ZendEngine2/zend_vm_execute.h Wed Aug 13 07:21:23 2008
@@ -13922,6 +13922,10 @@
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
}
zend_error(E_STRICT, "Only variables should be assigned by reference");
+ if (UNEXPECTED(EG(exception) != NULL)) {
+ if (free_op2.var) {zval_ptr_dtor(&free_op2.var);};
+ ZEND_VM_NEXT_OPCODE();
+ }
return ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
} else if (IS_VAR == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) {
PZVAL_LOCK(*value_ptr_ptr);
@@ -16368,6 +16372,10 @@
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
}
zend_error(E_STRICT, "Only variables should be assigned by reference");
+ if (UNEXPECTED(EG(exception) != NULL)) {
+
+ ZEND_VM_NEXT_OPCODE();
+ }
return ZEND_ASSIGN_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
} else if (IS_CV == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) {
PZVAL_LOCK(*value_ptr_ptr);
@@ -27512,6 +27520,10 @@
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
}
zend_error(E_STRICT, "Only variables should be assigned by reference");
+ if (UNEXPECTED(EG(exception) != NULL)) {
+ if (free_op2.var) {zval_ptr_dtor(&free_op2.var);};
+ ZEND_VM_NEXT_OPCODE();
+ }
return ZEND_ASSIGN_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
} else if (IS_VAR == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) {
PZVAL_LOCK(*value_ptr_ptr);
@@ -29729,6 +29741,10 @@
PZVAL_LOCK(*value_ptr_ptr); /* undo the effect of get_zval_ptr_ptr() */
}
zend_error(E_STRICT, "Only variables should be assigned by reference");
+ if (UNEXPECTED(EG(exception) != NULL)) {
+
+ ZEND_VM_NEXT_OPCODE();
+ }
return ZEND_ASSIGN_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
} else if (IS_CV == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) {
PZVAL_LOCK(*value_ptr_ptr);
http://cvs.php.net/viewvc.cgi/ZendEngine2/tests/bug45805.phpt?view=markup&rev=1.1
Index: ZendEngine2/tests/bug45805.phpt
+++ ZendEngine2/tests/bug45805.phpt
--
Zend Engine CVS Mailing List (http://cvs.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php