From 2572ed9ed9e25ec03e82a395354daf6be2b59a25 Mon Sep 17 00:00:00 2001 From: Melanie Date: Fri, 25 Apr 2014 00:34:44 +0100 Subject: Adjust permissions to work hand in hand with what the viewer believes they are. This fixes the issue of "Show in Search" seeming resetting at random. --- .../CoreModules/World/Permissions/PermissionsModule.cs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs b/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs index 39f5a4a..e6a4283 100644 --- a/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs +++ b/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs @@ -901,7 +901,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions return permission; } - protected bool GenericParcelOwnerPermission(UUID user, ILandObject parcel, ulong groupPowers) + protected bool GenericParcelOwnerPermission(UUID user, ILandObject parcel, ulong groupPowers, bool allowEstateManager) { if (parcel.LandData.OwnerID == user) { @@ -916,7 +916,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions return true; } - if (IsEstateManager(user)) + if (allowEstateManager && IsEstateManager(user)) { return true; } @@ -943,7 +943,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); if (m_bypassPermissions) return m_bypassPermissionsValue; - return GenericParcelOwnerPermission(user, parcel, (ulong)GroupPowers.LandRelease); + return GenericParcelOwnerPermission(user, parcel, (ulong)GroupPowers.LandRelease, false); } private bool CanReclaimParcel(UUID user, ILandObject parcel, Scene scene) @@ -951,7 +951,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); if (m_bypassPermissions) return m_bypassPermissionsValue; - return GenericParcelOwnerPermission(user, parcel, 0); + return GenericParcelOwnerPermission(user, parcel, 0,true); } private bool CanDeedParcel(UUID user, ILandObject parcel, Scene scene) @@ -968,7 +968,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions if ((client.GetGroupPowers(parcel.LandData.GroupID) & (ulong)GroupPowers.LandDeed) == 0) return false; - return GenericParcelOwnerPermission(user, parcel, (ulong)GroupPowers.LandDeed); + return GenericParcelOwnerPermission(user, parcel, (ulong)GroupPowers.LandDeed, false); } private bool CanDeedObject(UUID user, UUID group, Scene scene) @@ -1055,7 +1055,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); if (m_bypassPermissions) return m_bypassPermissionsValue; - return GenericParcelOwnerPermission(user, parcel, (ulong)p); + return GenericParcelOwnerPermission(user, parcel, (ulong)p, false); } /// @@ -1501,7 +1501,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); if (m_bypassPermissions) return m_bypassPermissionsValue; - return GenericParcelOwnerPermission(user, parcel, (ulong)GroupPowers.LandSetSale); + return GenericParcelOwnerPermission(user, parcel, (ulong)GroupPowers.LandSetSale, false); } private bool CanTakeObject(UUID objectID, UUID stealer, Scene scene) -- cgit v1.1