cvs: ZendEngine2 / zend.c

From: Date: Thu, 09 Jun 2005 10:31:54 +0000
Subject: cvs: ZendEngine2 / zend.c
Groups: php.zend-engine.cvs 
Request: Send a blank email to php-zend-engine-cvs+get-3776@lists.php.net to get a copy of this message
dmitry Thu Jun 9 06:31:54 2005 EDT Modified files: /ZendEngine2 zend.c Log: Fixed bug #25922 (In error handler, modifying 5th arg (errcontext) may result in seg fault) http://cvs.php.net/diff.php/ZendEngine2/zend.c?r1=1.301&r2=1.302&ty=u Index: ZendEngine2/zend.c diff -u ZendEngine2/zend.c:1.301 ZendEngine2/zend.c:1.302 --- ZendEngine2/zend.c:1.301 Sun May 22 07:10:38 2005 +++ ZendEngine2/zend.c Thu Jun 9 06:31:52 2005 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: zend.c,v 1.301 2005/05/22 11:10:38 stas Exp $ */ +/* $Id: zend.c,v 1.302 2005/06/09 10:31:52 dmitry Exp $ */ #include "zend.h" #include "zend_extensions.h" @@ -980,6 +980,9 @@ EG(user_error_handler) = NULL; if (call_user_function_ex(CG(function_table), NULL, orig_user_error_handler, &retval, 5, params, 1, NULL TSRMLS_CC)==SUCCESS) { + if (Z_TYPE_P(z_context) != IS_ARRAY || z_context->value.ht != EG(active_symbol_table)) { + zend_error(E_ERROR, "User error handler must not modify error context"); + } if (retval) { if (Z_TYPE_P(retval) == IS_BOOL && Z_LVAL_P(retval) == 0) { zend_error_cb(type, error_filename, error_lineno, format, args);

« previous php.zend-engine.cvs (#3776) next »