iliaa Sun, 11 Mar 2012 18:15:13 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=324112
Log: Fixed bug #60569 (Nullbyte truncates Exception $message). Bug: https://bugs.php.net/60569 (Open) Nullbyte truncates Exception $message. Changed paths: U php/php-src/branches/PHP_5_3/NEWS A php/php-src/branches/PHP_5_3/Zend/tests/bug60569.phpt U php/php-src/branches/PHP_5_3/Zend/zend_exceptions.c U php/php-src/branches/PHP_5_4/NEWS A php/php-src/branches/PHP_5_4/Zend/tests/bug60569.phpt U php/php-src/branches/PHP_5_4/Zend/zend_exceptions.c A php/php-src/trunk/Zend/tests/bug60569.phpt U php/php-src/trunk/Zend/zend_exceptions.c Modified: php/php-src/branches/PHP_5_3/NEWS =================================================================== --- php/php-src/branches/PHP_5_3/NEWS 2012-03-11 15:56:56 UTC (rev 324111) +++ php/php-src/branches/PHP_5_3/NEWS 2012-03-11 18:15:13 UTC (rev 324112) @@ -21,6 +21,7 @@ . Fixed bug #60825 (Segfault when running symfony 2 tests). (Dmitry, Laruence) . Fixed bug #60801 (strpbrk() mishandles NUL byte). (Adam) + . Fixed bug #60569 (Nullbyte truncates Exception $message). (Ilia) . Fixed bug #60227 (header() cannot detect the multi-line header with CR). (rui, Gustavo) . Fixed bug #52719 (array_walk_recursive crashes if third param of the Added: php/php-src/branches/PHP_5_3/Zend/tests/bug60569.phpt =================================================================== (Binary files differ) Property changes on: php/php-src/branches/PHP_5_3/Zend/tests/bug60569.phpt ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Modified: php/php-src/branches/PHP_5_3/Zend/zend_exceptions.c =================================================================== --- php/php-src/branches/PHP_5_3/Zend/zend_exceptions.c 2012-03-11 15:56:56 UTC (rev 324111) +++ php/php-src/branches/PHP_5_3/Zend/zend_exceptions.c 2012-03-11 18:15:13 UTC (rev 324112) @@ -192,7 +192,7 @@ object = getThis(); if (message) { - zend_update_property_string(default_exception_ce, object, "message", sizeof("message")-1, message TSRMLS_CC); + zend_update_property_stringl(default_exception_ce, object, "message", sizeof("message")-1, message, message_len TSRMLS_CC); } if (code) { Modified: php/php-src/branches/PHP_5_4/NEWS =================================================================== --- php/php-src/branches/PHP_5_4/NEWS 2012-03-11 15:56:56 UTC (rev 324111) +++ php/php-src/branches/PHP_5_4/NEWS 2012-03-11 18:15:13 UTC (rev 324112) @@ -32,6 +32,7 @@ error). (Stefan) . Fixed bug #60573 (type hinting with "self" keyword causes weird errors). (Laruence) + . Fixed bug #60569 (Nullbyte truncates Exception $message). (Ilia) . Fixed bug #52719 (array_walk_recursive crashes if third param of the function is by reference). (Nikita Popov) Added: php/php-src/branches/PHP_5_4/Zend/tests/bug60569.phpt =================================================================== (Binary files differ) Property changes on: php/php-src/branches/PHP_5_4/Zend/tests/bug60569.phpt ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Modified: php/php-src/branches/PHP_5_4/Zend/zend_exceptions.c =================================================================== --- php/php-src/branches/PHP_5_4/Zend/zend_exceptions.c 2012-03-11 15:56:56 UTC (rev 324111) +++ php/php-src/branches/PHP_5_4/Zend/zend_exceptions.c 2012-03-11 18:15:13 UTC (rev 324112) @@ -205,7 +205,7 @@ object = getThis(); if (message) { - zend_update_property_string(default_exception_ce, object, "message", sizeof("message")-1, message TSRMLS_CC); + zend_update_property_stringl(default_exception_ce, object, "message", sizeof("message")-1, message, message_len TSRMLS_CC); } if (code) { Added: php/php-src/trunk/Zend/tests/bug60569.phpt =================================================================== (Binary files differ) Property changes on: php/php-src/trunk/Zend/tests/bug60569.phpt ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Modified: php/php-src/trunk/Zend/zend_exceptions.c =================================================================== --- php/php-src/trunk/Zend/zend_exceptions.c 2012-03-11 15:56:56 UTC (rev 324111) +++ php/php-src/trunk/Zend/zend_exceptions.c 2012-03-11 18:15:13 UTC (rev 324112) @@ -205,7 +205,7 @@ object = getThis(); if (message) { - zend_update_property_string(default_exception_ce, object, "message", sizeof("message")-1, message TSRMLS_CC); + zend_update_property_stringl(default_exception_ce, object, "message", sizeof("message")-1, message, message_len TSRMLS_CC); } if (code) {
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php