|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2003-09-01 20:23 UTC] sniper@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Oct 30 22:00:01 2025 UTC |
Description: ------------ When I run is_dir() on FreeBSD 4.3, and the file I check is not a dir, I get a warning, about that the file is not a dir (duh, that is what I am checking for :p). On Windows systems I don't have this problem. Temporary solved the problem by using @is_dir(). But I believe it is not very logic. Reproduce code: --------------- if (is_dir("file.txt")) { echo "This shouldn't be a dir"; } else { echo "burp"; } Expected result: ---------------- burp Actual result: -------------- Warning: is_dir(): Stat failed for /www/site/file.txt (errno=20 - Not a directory) in /www/site on line 1 burp