kalle Wed Jul 1 17:42:48 2009 UTC Modified files: /php-src/ext/reflection php_reflection.c Log: Fixed memory leak if zero parameters are passed, Thanks Felipe http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/php_reflection.c?r1=1.347&r2=1.348&diff_format=u Index: php-src/ext/reflection/php_reflection.c diff -u php-src/ext/reflection/php_reflection.c:1.347 php-src/ext/reflection/php_reflection.c:1.348 --- php-src/ext/reflection/php_reflection.c:1.347 Wed Jul 1 17:37:42 2009 +++ php-src/ext/reflection/php_reflection.c Wed Jul 1 17:42:48 2009 @@ -20,7 +20,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: php_reflection.c,v 1.347 2009/07/01 17:37:42 kalle Exp $ */ +/* $Id: php_reflection.c,v 1.348 2009/07/01 17:42:48 kalle Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -1800,7 +1800,9 @@ result = zend_call_function(&fci, &fcc TSRMLS_CC); - efree(params); + if (num_args) { + efree(params); + } if (result == FAILURE) { zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, @@ -5687,7 +5689,7 @@ php_info_print_table_start(); php_info_print_table_header(2, "Reflection", "enabled"); - php_info_print_table_row(2, "Version", "$Revision: 1.347 $"); + php_info_print_table_row(2, "Version", "$Revision: 1.348 $"); php_info_print_table_end(); } /* }}} */ @@ -5701,7 +5703,7 @@ NULL, NULL, PHP_MINFO(reflection), - "$Revision: 1.347 $", + "$Revision: 1.348 $", STANDARD_MODULE_PROPERTIES }; /* }}} */
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php