diff options
Diffstat (limited to 'OpenSim/Region/Framework')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Scene.Inventory.cs | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs index 6031697..7060ef4 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs | |||
@@ -1151,34 +1151,20 @@ namespace OpenSim.Region.Framework.Scenes | |||
1151 | return; | 1151 | return; |
1152 | } | 1152 | } |
1153 | 1153 | ||
1154 | UUID partUUID = part.UUID; | ||
1155 | SceneObjectGroup group = part.ParentGroup; | ||
1156 | if (group != null) | ||
1157 | partUUID = group.RootPart.UUID; | ||
1158 | |||
1159 | TaskInventoryItem taskItem = part.Inventory.GetInventoryItem(itemId); | 1154 | TaskInventoryItem taskItem = part.Inventory.GetInventoryItem(itemId); |
1160 | 1155 | ||
1161 | if (null == taskItem) | ||
1162 | { | ||
1163 | m_log.WarnFormat("[PRIM INVENTORY]: Move of inventory item {0} from prim with local id {1} failed" | ||
1164 | + " because the inventory item could not be found", | ||
1165 | itemId, primLocalId); | ||
1166 | |||
1167 | return; | ||
1168 | } | ||
1169 | |||
1170 | if ((taskItem.CurrentPermissions & (uint)PermissionMask.Copy) == 0) | 1156 | if ((taskItem.CurrentPermissions & (uint)PermissionMask.Copy) == 0) |
1171 | { | 1157 | { |
1172 | // If the item to be moved is no copy, we need to be able to | 1158 | // If the item to be moved is no copy, we need to be able to |
1173 | // edit the prim. | 1159 | // edit the prim. |
1174 | if (!Permissions.CanEditObjectInventory(partUUID, remoteClient.AgentId)) | 1160 | if (!Permissions.CanEditObjectInventory(part.UUID, remoteClient.AgentId)) |
1175 | return; | 1161 | return; |
1176 | } | 1162 | } |
1177 | else | 1163 | else |
1178 | { | 1164 | { |
1179 | // If the item is copiable, then we just need to have perms | 1165 | // If the item is copiable, then we just need to have perms |
1180 | // on it. The delete check is a pure rights check | 1166 | // on it. The delete check is a pure rights check |
1181 | if (!Permissions.CanDeleteObject(partUUID, remoteClient.AgentId)) | 1167 | if (!Permissions.CanDeleteObject(part.UUID, remoteClient.AgentId)) |
1182 | return; | 1168 | return; |
1183 | } | 1169 | } |
1184 | 1170 | ||