Re: [PEPr] +1 for Tools and Utilities::Address_Book

From: Date: Sun, 05 Dec 2004 12:49:54 +0000
Subject: Re: [PEPr] +1 for Tools and Utilities::Address_Book
References: 1 2 3 4  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-34813@lists.php.net to get a copy of this message
On Sun, 05 Dec 2004 20:46:15 +0800, Alan Knowles <alan@akbkhome.com> wrote: > If it is possible that the file access may fail, doing > file_exists/isreadable prior to access is a little better than error > hiding - which should really only be regarded as a last resort or a > quick/temporary kludge. No, it's worse. It introduces race conditions. Nothing guarantees that nothing happens between the call to file_exists/is_readable and the call to fopen. The best way is really to use @fopen and use track_errors. Regards, Stefan

« previous php.pear.dev (#34813) next »