diff --git a/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs b/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs index 013a0ef4c5..c9b307156c 100644 --- a/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs +++ b/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs @@ -800,30 +800,31 @@ namespace OpenSim.Region.CoreModules.World.Permissions } protected bool GenericParcelOwnerPermission(UUID user, ILandObject parcel, ulong groupPowers) - { - bool permission = false; - + { if (parcel.LandData.OwnerID == user) { - permission = true; + // Returning immediately so that group deeded objects on group deeded land don't trigger a NRE on + // the subsequent redundant checks when using lParcelMediaCommandList() + // See http://opensimulator.org/mantis/view.php?id=3999 for more details + return true; } if (parcel.LandData.IsGroupOwned && IsGroupMember(parcel.LandData.GroupID, user, groupPowers)) { - permission = true; + return true; } if (IsEstateManager(user)) { - permission = true; + return true; } if (IsAdministrator(user)) { - permission = true; + return true; } - return permission; + return false; } protected bool GenericParcelPermission(UUID user, Vector3 pos, ulong groupPowers)