cvs: php-src(PHP_5_0) / NEWS /ext/standard file.c /main/streams plain_wrapper.c

From: Date: Wed, 06 Apr 2005 13:59:50 +0000
Subject: cvs: php-src(PHP_5_0) / NEWS /ext/standard file.c /main/streams plain_wrapper.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-31259@lists.php.net to get a copy of this message
iliaa Wed Apr 6 09:59:50 2005 EDT Modified files: (Branch: PHP_5_0) /php-src/ext/standard file.c /php-src/main/streams plain_wrapper.c /php-src NEWS Log: MFH: Fixed bug #31363 (broken non-blocking flock()). http://cvs.php.net/diff.php/php-src/ext/standard/file.c?r1=1.382.2.8&r2=1.382.2.9&ty=u Index: php-src/ext/standard/file.c diff -u php-src/ext/standard/file.c:1.382.2.8 php-src/ext/standard/file.c:1.382.2.9 --- php-src/ext/standard/file.c:1.382.2.8 Sun Mar 27 10:53:30 2005 +++ php-src/ext/standard/file.c Wed Apr 6 09:59:48 2005 @@ -21,7 +21,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: file.c,v 1.382.2.8 2005/03/27 15:53:30 iliaa Exp $ */ +/* $Id: file.c,v 1.382.2.9 2005/04/06 13:59:48 iliaa Exp $ */ /* Synced with php 3.0 revision 1.218 1999-06-16 [ssb] */ @@ -275,13 +275,13 @@ /* flock_values contains all possible actions if (operation & 4) we won't block on the lock */ act = flock_values[act - 1] | (operation & 4 ? LOCK_NB : 0); - if (!php_stream_lock(stream, act)) { + if (php_stream_lock(stream, act)) { if (operation && errno == EWOULDBLOCK && arg3 && PZVAL_IS_REF(arg3)) { Z_LVAL_P(arg3) = 1; } - RETURN_TRUE; + RETURN_FALSE; } - RETURN_FALSE; + RETURN_TRUE; } /* }}} */ http://cvs.php.net/diff.php/php-src/main/streams/plain_wrapper.c?r1=1.39.2.3&r2=1.39.2.4&ty=u Index: php-src/main/streams/plain_wrapper.c diff -u php-src/main/streams/plain_wrapper.c:1.39.2.3 php-src/main/streams/plain_wrapper.c:1.39.2.4 --- php-src/main/streams/plain_wrapper.c:1.39.2.3 Thu Oct 28 01:05:39 2004 +++ php-src/main/streams/plain_wrapper.c Wed Apr 6 09:59:48 2005 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: plain_wrapper.c,v 1.39.2.3 2004/10/28 05:05:39 tony2001 Exp $ */ +/* $Id: plain_wrapper.c,v 1.39.2.4 2005/04/06 13:59:48 iliaa Exp $ */ #include "php.h" #include "php_globals.h" @@ -578,7 +578,7 @@ return 0; } - if (!flock(fd, value) || (errno == EWOULDBLOCK && value & LOCK_NB)) { + if (!flock(fd, value)) { data->lock_flag = value; return 0; } else { http://cvs.php.net/diff.php/php-src/NEWS?r1=1.1760.2.311&r2=1.1760.2.312&ty=u Index: php-src/NEWS diff -u php-src/NEWS:1.1760.2.311 php-src/NEWS:1.1760.2.312 --- php-src/NEWS:1.1760.2.311 Wed Apr 6 02:48:12 2005 +++ php-src/NEWS Wed Apr 6 09:59:48 2005 @@ -9,6 +9,7 @@ - Fixed bug #32491 (File upload error - unable to create a temporary file). (Uwe Schindler) - Fixed bug #32282 (Segfault in mysqli_fetch_array on 64-bit) (Georg). +- Fixed bug #31363 (broken non-blocking flock()). ian at snork dot net - Fixed bug #28839 (SIGSEGV in interactive mode (php -a)). (kameshj at fastmail dot fm)

« previous php.cvs (#31259) next »