tony2001 Thu Feb 2 12:19:14 2006 UTC Modified files: (Branch: PHP_5_1) /php-src NEWS /php-src/ext/spl spl_directory.c Log: fix #36258 (SplFileObject::getPath() may lead to segfault) http://cvs.php.net/viewcvs.cgi/php-src/NEWS?r1=1.2027.2.393&r2=1.2027.2.394&diff_format=u Index: php-src/NEWS diff -u php-src/NEWS:1.2027.2.393 php-src/NEWS:1.2027.2.394 --- php-src/NEWS:1.2027.2.393 Thu Feb 2 11:41:45 2006 +++ php-src/NEWS Thu Feb 2 12:19:13 2006 @@ -19,6 +19,7 @@ - Added imap_savebody() that allows message body to be written to a file. (Mike) - Fixed imagecolorallocate() and imagecolorallocatelapha() to return FALSE on error. (Pierre) +- Fixed bug #36258 (SplFileObject::getPath() may lead to segfault). (Tony) - Fixed bug #36242 (Possible memory corruption in stream_select()). (Tony) - Fixed bug #36235 (ocicolumnname returns false before a succesfull fetch). (Tony) http://cvs.php.net/viewcvs.cgi/php-src/ext/spl/spl_directory.c?r1=1.45.2.13&r2=1.45.2.14&diff_format=u Index: php-src/ext/spl/spl_directory.c diff -u php-src/ext/spl/spl_directory.c:1.45.2.13 php-src/ext/spl/spl_directory.c:1.45.2.14 --- php-src/ext/spl/spl_directory.c:1.45.2.13 Mon Jan 23 15:24:10 2006 +++ php-src/ext/spl/spl_directory.c Thu Feb 2 12:19:14 2006 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: spl_directory.c,v 1.45.2.13 2006/01/23 15:24:10 iliaa Exp $ */ +/* $Id: spl_directory.c,v 1.45.2.14 2006/02/02 12:19:14 tony2001 Exp $ */ #ifdef HAVE_CONFIG_H # include "config.h" @@ -340,6 +340,8 @@ spl_filesystem_object_get_file_name(source TSRMLS_CC); intern->file_name = estrndup(source->file_name, source->file_name_len); intern->file_name_len = source->file_name_len; + intern->path = estrndup(source->path, source->path_len); + intern->path_len = source->path_len; break; case SPL_FS_FILE: return_value->value.obj = spl_filesystem_object_new_ex(ce ? ce : source->file_class, &intern TSRMLS_CC);
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php