mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 14:18:52 +00:00
suppress warnings (stat failed). Though may be good to know... why!
git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@9519 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
6e11b7181d
commit
928fc7be97
1 changed files with 6 additions and 6 deletions
|
@ -541,8 +541,8 @@ function phpbb_chmod($filename, $perms = CHMOD_READ)
|
|||
global $phpbb_root_path, $phpEx;
|
||||
|
||||
// Determine owner/group of common.php file and the filename we want to change here
|
||||
$common_php_owner = fileowner($phpbb_root_path . 'common.' . $phpEx);
|
||||
$common_php_group = filegroup($phpbb_root_path . 'common.' . $phpEx);
|
||||
$common_php_owner = @fileowner($phpbb_root_path . 'common.' . $phpEx);
|
||||
$common_php_group = @filegroup($phpbb_root_path . 'common.' . $phpEx);
|
||||
|
||||
// And the owner and the groups PHP is running under.
|
||||
$php_uid = (function_exists('posix_getuid')) ? @posix_getuid() : false;
|
||||
|
@ -568,21 +568,21 @@ function phpbb_chmod($filename, $perms = CHMOD_READ)
|
|||
|
||||
if ($_chmod_info['process'])
|
||||
{
|
||||
$file_uid = fileowner($filename);
|
||||
$file_gid = filegroup($filename);
|
||||
$file_uid = @fileowner($filename);
|
||||
$file_gid = @filegroup($filename);
|
||||
|
||||
// Change owner
|
||||
if (@chown($filename, $_chmod_info['common_owner']))
|
||||
{
|
||||
clearstatcache();
|
||||
$file_uid = fileowner($filename);
|
||||
$file_uid = @fileowner($filename);
|
||||
}
|
||||
|
||||
// Change group
|
||||
if (@chgrp($filename, $_chmod_info['common_group']))
|
||||
{
|
||||
clearstatcache();
|
||||
$file_gid = filegroup($filename);
|
||||
$file_gid = @filegroup($filename);
|
||||
}
|
||||
|
||||
// If the file_uid/gid now match the one from common.php we can process further, else we are not able to change something
|
||||
|
|
Loading…
Add table
Reference in a new issue