iliaa Tue Apr 18 00:31:45 2006 UTC Modified files: (Branch: PHP_5_1) /php-src/ext/session mod_files.c Log: Commit the actual fix http://cvs.php.net/viewcvs.cgi/php-src/ext/session/mod_files.c?r1=1.100.2.2&r2=1.100.2.3&diff_format=u Index: php-src/ext/session/mod_files.c diff -u php-src/ext/session/mod_files.c:1.100.2.2 php-src/ext/session/mod_files.c:1.100.2.3 --- php-src/ext/session/mod_files.c:1.100.2.2 Sun Jan 1 12:50:12 2006 +++ php-src/ext/session/mod_files.c Tue Apr 18 00:31:45 2006 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: mod_files.c,v 1.100.2.2 2006/01/01 12:50:12 sniper Exp $ */ +/* $Id: mod_files.c,v 1.100.2.3 2006/04/18 00:31:45 iliaa Exp $ */ #include "php.h" @@ -397,10 +397,12 @@ if (!ps_files_path_create(buf, sizeof(buf), data, key)) return FAILURE; - ps_files_close(data); + if (data->fd != -1) { + ps_files_close(data); - if (VCWD_UNLINK(buf) == -1) { - return FAILURE; + if (VCWD_UNLINK(buf) == -1) { + return FAILURE; + } } return SUCCESS;
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php