Re: file locks
| From: | Liam Gibbs | Date: | Tue, 09 Apr 2002 14:39:10 +0000 |
| Subject: | Re: file locks | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-92235@lists.php.net to get a copy of this message | ||
<<Is there a way for a script to tell if the file it's
trying to access is locked by other script (via
flock()) or not. I need to make script wait untill
other script running in a parallel thread releases the
lock on the file.>>
Without testing, would this work? Just a suggestion
(read: shot in the dark) that may work.
while(!$filehandle) {
$filehandle = @fopen("file_in_question",
"r/w/whatever");
}
<<Tnx in advance.>>
You're welcome in advance. :)
__________________________________________________
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/