"fix for bug #2041: Postrgresql error when I try to access a file in sqlfs

\"CEST ERROR:  argument of AND must be type boolean, not type integer\"
"
This commit is contained in:
Ralf Becker 2009-04-15 07:50:14 +00:00
parent 74fd4858b6
commit e20bd1703b

View File

@ -1046,8 +1046,8 @@ class sqlfs_stream_wrapper implements iface_stream_wrapper
{
$memberships[] = abs($gid); // sqlfs stores the gid's positiv
}
$sql_read_acl = '(fs_mode & 04 OR fs_mode & 0400 AND fs_uid='.(int)egw_vfs::$user.
' OR fs_mode & 040 AND fs_gid IN('.implode(',',$memberships).'))';
$sql_read_acl = '((fs_mode & 04)=04 OR (fs_mode & 0400)=0400 AND fs_uid='.(int)egw_vfs::$user.
' OR (fs_mode & 040)=040 AND fs_gid IN('.implode(',',$memberships).'))';
}
return $sql_read_acl;
}