|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2000-08-20 04:02 UTC] sniper@php.net
[2000-09-03 19:49 UTC] sniper@php.net
[2000-10-02 22:28 UTC] sniper@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Oct 28 15:00:02 2025 UTC |
The function php_dbm_open() in db.c contains the following lines ... if (lockfd) { flock(lockfd,LOCK_EX); close(lockfd); } else { php_error(E_WARNING, "Unable to establish lock: %s",filename); } I don't think that this will achieve what is intended - at least not under Solaris where PHP implements flock() in terms of fnctl(). (I strongly suspect that this problem will also show itself under other versions of UNIX). The reason is that the lock will be released immediately after it is obtained by the call to close(). I noticed this problem under PHP 3.0.12 but I have looked at the source code of PHP 4.0.0 to verify that this problem hasn't been fixed there.