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:25 +00:00
parent 418578dc2f
commit 21a1f6ea64

View File

@ -599,7 +599,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 ());