#48618 [Com]: getPerms doesn't returns right perms
| From: | majkl578 at gmail dot com | Date: | Sat, 20 Jun 2009 22:01:15 +0000 |
| Subject: | #48618 [Com]: getPerms doesn't returns right perms | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-138574@lists.php.net to get a copy of this message | ||
ID: 48618
Comment by: majkl578 at gmail dot com
Reported By: agiorg at gmail dot com
Status: Open
Bug Type: SPL related
Operating System: ubuntu
PHP Version: 5.3.0RC4
New Comment:
tested code:
<?php
mkdir('/tmp/test', 0744);
$dir=new DirectoryIterator('/tmp/test');
var_dump(decoct($dir->getPerms()));
?>
-------
returns 41777
-------
OS: Debian Lenny (unstable)
PHP Version: PHP 5.3.0RC4
Previous Comments:
------------------------------------------------------------------------
[2009-06-20 15:56:24] agiorg at gmail dot com
Description:
------------
We are actually testing the DirectoryIterator class (we're joining the
TestFest). So, the virtual machine we're working on runs PHP 5.3.0RC3.
After creating a new folder, both using mkdir or shell_exec('mkdir'),
getPerms doesn't returns right perms (we checked out straightly on the
shell and the permissions were as expected).
Reproduce code:
---------------
mkdir('test', 0744);
$dir=new DirectoryIterator('test');
var_dump(decoct($dir->getPerms()));
Expected result:
----------------
string(5) "40744"
Actual result:
--------------
string(5) "40755"
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=48618&edit=1