From 4480d5527b4f88ffc0cd22ec87e7842e786e77a3 Mon Sep 17 00:00:00 2001 From: Homer Horwitz Date: Mon, 1 Dec 2008 22:28:17 +0000 Subject: Fix Mantis#2527. Permissions returned false for editing non-root SOPs. Now, they will use the SOG the SOP belongs to (as it was for the root-SOP already). --- .../Environment/Modules/World/Permissions/PermissionsModule.cs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs b/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs index 92e040f..1fe7df7 100644 --- a/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs +++ b/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs @@ -698,6 +698,14 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions SceneObjectPart part = m_scene.GetSceneObjectPart(objectID); + // If we selected a sub-prim to edit, the objectID won't represent the object, but only a part. + // We have to check the permissions of the group, though. + if (part.ParentID != 0) + { + objectID = part.ParentUUID; + part = m_scene.GetSceneObjectPart(objectID); + } + // TODO: add group support! // if (part.OwnerID != editorID) -- cgit v1.1