Re: is_link() behavior
| From: | J. Jones | Date: | Tue, 24 Apr 2001 03:29:56 +0000 |
| Subject: | Re: is_link() behavior | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-50007@lists.php.net to get a copy of this message | ||
On Tue, Apr 24, 2001 at 05:31:04AM +0200, Martin Skjöldebrand wrote:
> > Warning: stat failed for /tmp/this_is_a_symlink (errno=2 - No such file or
> > directory) in ./test.php on line 3.
>
> Do you have permission to read the /tmp catalog? Otherwise you may get that
> error I suppose.
>
> M.
Yes.. the script was executed as root, so permissions aren't an issue. ;)
The error, I believe, is generated from is_link() trying to do a stat() on
the link's target, which doesn't exist. The symlink is broken the second
time around (foo doesn't exist).