do no call posix_* methods (from posix extension), if it is not available

This commit is contained in:
Ralf Becker 2014-10-07 09:31:53 +00:00
parent d52b767797
commit 6a9558e2a7

View File

@ -600,7 +600,7 @@ class asyncservice
{
echo '<p>'.lang('%1 is not executable by the webserver !!!',$this->$name)."</p>\n";
$perms = fileperms($this->$name);
if (!($perms & 0x0001) && ($perms & 0x0008)) // only executable by group
if (!($perms & 0x0001) && ($perms & 0x0008) && function_exists('posix_getuid')) // only executable by group
{
$group = posix_getgrgid(filegroup($this->$name));
$webserver = posix_getpwuid(posix_getuid ());