|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2007-09-23 15:19 UTC] iliaa@php.net
[2007-11-27 12:36 UTC] yurtesen at ispro dot net
[2008-02-18 11:09 UTC] jani@php.net
[2008-02-26 01:00 UTC] php-bugs at lists dot php dot net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Oct 23 14:00:02 2025 UTC |
Description: ------------ When safe_mode is enabled mkdir('newdir/',0770); doesnt function. When safe_mode is disabled it functions fine. Sure, there shouldnt be a trailing slash there perhaps but most PHP software uses paths similar to '/home/user/domain/test/' so this is a problem. This appeared in 5.2.3 or 5.2.4 I am not so sure. This is not a permissions based problem as the folder is created when backslash is not used in safe_mode, and it is created when backslash is used and NOT in safe_mode It seems to be the same bug with(perhaps somehow reintroduced?): http://bugs.php.net/bug.php?id=16638 Reproduce code: --------------- <?php mkdir('myhomefolder/',0770); //mkdir('myhomefolder',0770); ?> The problem is the trailing slash and safe_mode... Expected result: ---------------- myhomefolder should get created. Actual result: -------------- Warning: mkdir(): Unable to access myhomefolder/ in /home/user/domain/test.php on line 3