Re: Minor Cache Bug
| From: | Martin Jansen | Date: | Wed, 02 May 2001 19:55:56 +0000 |
| Subject: | Re: Minor Cache Bug | ||
| Groups: | php.pear.dev | ||
| Request: | Send a blank email to pear-dev+get-341@lists.php.net to get a copy of this message | ||
On Wed, 2 May 2001 22:47:01 +0300, yavo wrote:
>in Cache/Container/File.php
>
>on line 129
><< $ok = unlink($file);
>fails if the file does not excist
>change to
>>> $ok = @unlink($file);
>to avoid end of execution if invallid id is given by mistake
I suppose you're talking about line 138 in latest CVS, right?
In line 129 I could not the quoted line.
But I don't think that this statement can cause a bug.
The whole block around unlink is:
if (file_exists($file)) {
$ok = unlink($file);
clearstatcache();
return $ok;
}
Only if the file really exists, unlink() is called.
- Martin