cvs: ZendEngine2(PHP_5_3) / zend_compile.c

From: Date: Tue, 18 Mar 2008 11:37:01 +0000
Subject: cvs: ZendEngine2(PHP_5_3) / zend_compile.c
Groups: php.zend-engine.cvs 
Request: Send a blank email to php-zend-engine-cvs+get-6539@lists.php.net to get a copy of this message
dmitry Tue Mar 18 11:37:01 2008 UTC Modified files: (Branch: PHP_5_3) /ZendEngine2 zend_compile.c Log: Removed hack (we don't need to modify class name). (the problem is covered by Zend/tests/ns_056.phpt) http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_compile.c?r1=1.647.2.27.2.41.2.52&r2=1.647.2.27.2.41.2.53&diff_format=u Index: ZendEngine2/zend_compile.c diff -u ZendEngine2/zend_compile.c:1.647.2.27.2.41.2.52 ZendEngine2/zend_compile.c:1.647.2.27.2.41.2.53 --- ZendEngine2/zend_compile.c:1.647.2.27.2.41.2.52 Tue Mar 18 08:36:28 2008 +++ ZendEngine2/zend_compile.c Tue Mar 18 11:37:00 2008 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: zend_compile.c,v 1.647.2.27.2.41.2.52 2008/03/18 08:36:28 dmitry Exp $ */ +/* $Id: zend_compile.c,v 1.647.2.27.2.41.2.53 2008/03/18 11:37:00 dmitry Exp $ */ #include <zend_language_parser.h> #include "zend.h" @@ -2278,14 +2278,10 @@ && strcasecmp(fe->common.arg_info[i].class_name, proto->common.arg_info[i].class_name)!=0) { char *colon; - if (fe->common.type == ZEND_USER_FUNCTION && - strchr(proto->common.arg_info[i].class_name, ':') == NULL && - (colon = zend_memrchr(fe->common.arg_info[i].class_name, ':', fe->common.arg_info[i].class_name_len)) != NULL && - strcasecmp(colon+1, proto->common.arg_info[i].class_name) == 0) { - efree((char*)fe->common.arg_info[i].class_name); - fe->common.arg_info[i].class_name = estrndup(proto->common.arg_info[i].class_name, proto->common.arg_info[i].class_name_len); - fe->common.arg_info[i].class_name_len = proto->common.arg_info[i].class_name_len; - } else { + if (fe->common.type != ZEND_USER_FUNCTION || + strchr(proto->common.arg_info[i].class_name, ':') != NULL || + (colon = zend_memrchr(fe->common.arg_info[i].class_name, ':', fe->common.arg_info[i].class_name_len)) == NULL || + strcasecmp(colon+1, proto->common.arg_info[i].class_name) != 0) { return 0; } }

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