#33865 [Opn->Csd]: local_retval_ptr should be initialized to NULL

From: Date: Tue, 26 Jul 2005 18:33:25 +0000
Subject: #33865 [Opn->Csd]: local_retval_ptr should be initialized to NULL
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-82479@lists.php.net to get a copy of this message
 ID:               33865
 Updated by:       sniper@php.net
 Reported By:      mike@php.net
-Status:           Open
+Status:           Closed
 Bug Type:         Scripting Engine problem
 Operating System: Windows 2000
 PHP Version:      5CVS-2005-07-26 (dev)
 New Comment:

Fixed. Please don't report these kind of things as bugs, 
send these to internals@ directly.



Previous Comments:
------------------------------------------------------------------------

[2005-07-26 13:46:48] mike@php.net

Description:
------------
In zend_execute_API.c zend_call_user_function() the local_retval_ptr
variable should be initialized to NULL; otherwise it could lead to a
memory read access failure.


Expected result:
----------------
Index: zend_execute_API.c
===================================================================
RCS file: /repository/ZendEngine2/zend_execute_API.c,v
retrieving revision 1.328
diff -u -r1.328 zend_execute_API.c
--- zend_execute_API.c	21 Jul 2005 16:52:32 -0000	1.328
+++ zend_execute_API.c	26 Jul 2005 11:42:27 -0000
@@ -531,7 +531,7 @@
 	zval ***params_array;
 	zend_uint i;
 	int ex_retval;
-	zval *local_retval_ptr;
+	zval *local_retval_ptr = NULL;
 
 	if (param_count) {
 		params_array = (zval ***) emalloc(sizeof(zval **)*param_count);




------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=33865&edit=1


Thread (2 messages)

« previous php.bugs (#82479) next »