Re: File locking problem

From: Date: Thu, 07 Nov 2002 05:36:11 +0000
Subject: Re: File locking problem
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-123106@lists.php.net to get a copy of this message
Marco Tabini wrote... > Just a (possibly stupid) suggestion--is it possible that the file is being > overwritten by another instance of your script that's run in the meantime? This may also be a problem at some point, but currently I'm just trying to get it working in an test environment where only one instance is running. I know I can just use another empty file as a semaphore, but my performance is already killed by having to use FTP to create and delete files with PHP, and I need to do whatever I can do avoid it. Basically, it appears that using fflush() and fclose() is no guarantee that a file is completely written, and I'm wondering what I can do besides insert sleep() statements. -- Charles Wiltgen "Love is a snowmobile racing across the tundra and then suddenly it flips over, pinning you underneath. At night, the ice weasels come." - Nietzsche (Groening)

« previous php.general (#123106) next »