ID: 50319 Updated by: j...@php.net Reported By: jpope at popes dot net -Status: Open +Status: Bogus Bug Type: Streams related Operating System: Fedora 12 PHP Version: 5.3.1 New Comment:
Please do not submit the same bug more than once. An existing bug report already describes this very problem. Even if you feel that your issue is somewhat different, the resolution is likely to be the same. Thank you for your interest in PHP. Previous Comments: ------------------------------------------------------------------------ [2009-11-28 19:46:43] jpope at popes dot net Description: ------------ stat() and lstat() functions fail when passed a file that is on a CIFS mounted file system. This issue is the same as bug #50150. Reproduce code: --------------- #!/usr/bin/php <?php $dirtoopen="/mnt/images/"; $dir = opendir($dirtoopen); if($dir) { if($file = readdir($dir)) { var_dump(stat("$dirtoopen$file")); } closedir($dir); } else { echo "Can't open dir \"$dirtoopen\"\n"; } ?> Expected result: ---------------- array(26) { [0]=> int(64768) [1]=> int(11) [2]=> int(16832) [3]=> int(2) [4]=> int(0) [5]=> int(0) [6]=> int(0) [7]=> int(16384) [8]=> int(1259424478) [9]=> int(1188876522) [10]=> int(1227920384) [11]=> int(4096) [12]=> int(40) ["dev"]=> int(64768) ["ino"]=> int(11) ["mode"]=> int(16832) ["nlink"]=> int(2) ["uid"]=> int(0) ["gid"]=> int(0) ["rdev"]=> int(0) ["size"]=> int(16384) ["atime"]=> int(1259424478) ["mtime"]=> int(1188876522) ["ctime"]=> int(1227920384) ["blksize"]=> int(4096) ["blocks"]=> int(40) } Actual result: -------------- PHP Warning: stat(): stat failed for /mnt/images/. in /root/x on line 9 bool(false) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=50319&edit=1