More perms fixes. Reinstate the move flag

0.6.0-stable
Melanie Thielker 2008-10-06 03:23:55 +00:00
parent 1f7966d6e8
commit c4ab9482b5
1 changed files with 10 additions and 6 deletions

View File

@ -248,21 +248,25 @@ namespace OpenSim.Region.Environment.Scenes
PermissionMask.Move |
PermissionMask.Transfer) | 7;
uint ownerMask = 0x7ffffff;
foreach (SceneObjectPart part in m_parts.Values)
{
ownerMask &= part.OwnerMask;
perms &= part.MaskEffectivePermissions();
}
if ((RootPart.OwnerMask & (uint)PermissionMask.Modify) == 0)
if (ownerMask & (uint)PermissionMask.Modify) == 0)
perms &= ~(uint)PermissionMask.Modify;
if ((RootPart.OwnerMask & (uint)PermissionMask.Copy) == 0)
if (ownerMask & (uint)PermissionMask.Copy) == 0)
perms &= ~(uint)PermissionMask.Copy;
if ((RootPart.OwnerMask & (uint)PermissionMask.Transfer) == 0)
if (ownerMask & (uint)PermissionMask.Transfer) == 0)
perms &= ~(uint)PermissionMask.Transfer;
if ((RootPart.OwnerMask & RootPart.NextOwnerMask & (uint)PermissionMask.Modify) == 0)
if (ownerMask & RootPart.NextOwnerMask & (uint)PermissionMask.Modify) == 0)
perms &= ~((uint)PermissionMask.Modify >> 13);
if ((RootPart.OwnerMask & RootPart.NextOwnerMask & (uint)PermissionMask.Copy) == 0)
if (ownerMask & RootPart.NextOwnerMask & (uint)PermissionMask.Copy) == 0)
perms &= ~((uint)PermissionMask.Copy >> 13);
if ((RootPart.OwnerMask & RootPart.NextOwnerMask & (uint)PermissionMask.Transfer) == 0)
if (ownerMask & RootPart.NextOwnerMask & (uint)PermissionMask.Transfer) == 0)
perms &= ~((uint)PermissionMask.Transfer >> 13);
return perms;