logo       
Google Custom Search
    AddThis Social Bookmark Button
-->

cvs: ZendEngine2 / zend_vm_def.h zend_vm_execute.h: msg#00013

Subject: cvs: ZendEngine2 / zend_vm_def.h zend_vm_execute.h
dmitry          Tue Oct  2 08:47:42 2007 UTC

  Modified files:              
    /ZendEngine2        zend_vm_def.h zend_vm_execute.h 
  Log:
  Fixed access to freed memory in tests/classes/__call_001.phpt
  
  
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_vm_def.h?r1=1.186&r2=1.187&diff_format=u
Index: ZendEngine2/zend_vm_def.h
diff -u ZendEngine2/zend_vm_def.h:1.186 ZendEngine2/zend_vm_def.h:1.187
--- ZendEngine2/zend_vm_def.h:1.186     Tue Oct  2 08:27:19 2007
+++ ZendEngine2/zend_vm_def.h   Tue Oct  2 08:47:42 2007
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: zend_vm_def.h,v 1.186 2007/10/02 08:27:19 dmitry Exp $ */
+/* $Id: zend_vm_def.h,v 1.187 2007/10/02 08:47:42 dmitry Exp $ */
 
 /* If you change this file, please regenerate the zend_vm_execute.h and
  * zend_vm_opcodes.h files by running:
@@ -2015,6 +2015,7 @@
        if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION) {
                ALLOC_ZVAL(EX_T(opline->result.u.var).var.ptr);
                INIT_ZVAL(*(EX_T(opline->result.u.var).var.ptr));
+        EX_T(opline->result.u.var).var.fcall_returned_reference = 
EX(function_state).function->common.return_reference;
 
                if (EX(function_state).function->common.arg_info) {
                        zend_uint i=0;
@@ -2047,8 +2048,6 @@
 */
                if (!return_value_used) {
                        zval_ptr_dtor(&EX_T(opline->result.u.var).var.ptr);
-               } else {
-                       EX_T(opline->result.u.var).var.fcall_returned_reference 
= EX(function_state).function->common.return_reference;
                }
        } else if (EX(function_state).function->type == ZEND_USER_FUNCTION) {
                HashTable *function_symbol_table;
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_vm_execute.h?r1=1.190&r2=1.191&diff_format=u
Index: ZendEngine2/zend_vm_execute.h
diff -u ZendEngine2/zend_vm_execute.h:1.190 ZendEngine2/zend_vm_execute.h:1.191
--- ZendEngine2/zend_vm_execute.h:1.190 Tue Oct  2 08:27:19 2007
+++ ZendEngine2/zend_vm_execute.h       Tue Oct  2 08:47:42 2007
@@ -182,6 +182,7 @@
        if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION) {
                ALLOC_ZVAL(EX_T(opline->result.u.var).var.ptr);
                INIT_ZVAL(*(EX_T(opline->result.u.var).var.ptr));
+        EX_T(opline->result.u.var).var.fcall_returned_reference = 
EX(function_state).function->common.return_reference;
 
                if (EX(function_state).function->common.arg_info) {
                        zend_uint i=0;
@@ -214,8 +215,6 @@
 */
                if (!return_value_used) {
                        zval_ptr_dtor(&EX_T(opline->result.u.var).var.ptr);
-               } else {
-                       EX_T(opline->result.u.var).var.fcall_returned_reference 
= EX(function_state).function->common.return_reference;
                }
        } else if (EX(function_state).function->type == ZEND_USER_FUNCTION) {
                HashTable *function_symbol_table;

-- 
Zend Engine CVS Mailing List (http://cvs.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




<Prev in Thread] Current Thread [Next in Thread>