|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2007-02-19 21:05 UTC] helly@php.net
[2007-02-19 21:19 UTC] info at adaniels dot nl
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 02 14:00:01 2025 UTC |
Description: ------------ SplFileInfo::getPathInfo() throws an execption if directory is in root dir. Reproduce code: --------------- <?php $fi = new SplFileInfo('/home'); echo $fi->getPathInfo()->getFilename(); ?> Expected result: ---------------- / Actual result: -------------- Fatal error: Uncaught exception 'RuntimeException' with message 'Cannot create SplFileInfo for empty path' in /home/arnold/projects/jasny/jasny-explorer/webroot/index.php:6 Stack trace: #0 /home/arnold/projects/jasny/jasny-explorer/webroot/index.php(6): SplFileInfo->getPathInfo() #1 {main} thrown in /home/arnold/projects/jasny/jasny-explorer/webroot/index.php on line 6