From 928fc7be976cabd45770728a3d496778a030de1e Mon Sep 17 00:00:00 2001 From: Meik Sievertsen Date: Sat, 23 May 2009 16:11:40 +0000 Subject: [PATCH] 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 --- phpBB/includes/functions.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/phpBB/includes/functions.php b/phpBB/includes/functions.php index be5e661d44..476565452c 100644 --- a/phpBB/includes/functions.php +++ b/phpBB/includes/functions.php @@ -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