Bug #51766 [NEW]: SplFileInfo::isLink() Fails for Symlinks on windows
| From: | v-sumada at microsoft dot com | Date: | Fri, 07 May 2010 17:08:09 +0000 |
| Subject: | Bug #51766 [NEW]: SplFileInfo::isLink() Fails for Symlinks on windows | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-150250@lists.php.net to get a copy of this message | ||
From:
Operating system: All Windows OS
PHP version: 5.3.2
Package: SPL related
Bug Type: Bug
Bug description:SplFileInfo::isLink() Fails for Symlinks on windows
Description:
------------
SplFileInfo::isLink() Which returns False for Symbolic links on all
windows OS. we have a File Symbolic link created for a file and tried to
test whether the referenced file by SplFileInfo is symbolic link or not.
In the above script we have a symlink(filesymlink)created for a file
'testfile' and tried to check with the file_exists function for
symlink(filesymlink) which returns true and it returns false for the
SplFileInfo::isLink().
Test script:
---------------
<?php
$symlinkname = "/path/to/filesymlink";
$fileinfo = new SplFileInfo($symlinkname);
var_dump(file_exists($symlinkname));
var_dump($fileinfo->isLink());
?>
Expected result:
----------------
bool(true)
bool(true)
Actual result:
--------------
bool(true)
bool(false)
--
Edit bug report at http://bugs.php.net/bug.php?id=51766&edit=1
--
Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=51766&r=trysnapshot52
Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=51766&r=trysnapshot53
Try a snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=51766&r=trysnapshot60
Fixed in SVN: http://bugs.php.net/fix.php?id=51766&r=fixed
Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=51766&r=needdocs
Fixed in release: http://bugs.php.net/fix.php?id=51766&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=51766&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=51766&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=51766&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=51766&r=support
Expected behavior: http://bugs.php.net/fix.php?id=51766&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=51766&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=51766&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=51766&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=51766&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=51766&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=51766&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=51766&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=51766&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=51766&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=51766&r=mysqlcfg