aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes
diff options
context:
space:
mode:
authorMelanie2011-01-10 22:02:22 +0100
committerMelanie2011-01-10 22:02:22 +0100
commit2c6a410e903767a9c4f18777ec0d9fd862fe531e (patch)
tree5d0411926bf5bcc5ba2035b3697afbe39fbf13d3 /OpenSim/Region/Framework/Scenes
parentTaint SOGs the right way (diff)
downloadopensim-SC-2c6a410e903767a9c4f18777ec0d9fd862fe531e.zip
opensim-SC-2c6a410e903767a9c4f18777ec0d9fd862fe531e.tar.gz
opensim-SC-2c6a410e903767a9c4f18777ec0d9fd862fe531e.tar.bz2
opensim-SC-2c6a410e903767a9c4f18777ec0d9fd862fe531e.tar.xz
Partial permissions fix for boxed items.
Diffstat (limited to 'OpenSim/Region/Framework/Scenes')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.Inventory.cs10
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs18
2 files changed, 18 insertions, 10 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
index 5658f90..1f32362 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
@@ -2171,5 +2171,15 @@ namespace OpenSim.Region.Framework.Scenes
2171 2171
2172 m_sceneGraph.LinkObjects(root, children); 2172 m_sceneGraph.LinkObjects(root, children);
2173 } 2173 }
2174
2175 private string PermissionString(uint permissions)
2176 {
2177 PermissionMask perms = (PermissionMask)permissions &
2178 (PermissionMask.Move |
2179 PermissionMask.Copy |
2180 PermissionMask.Transfer |
2181 PermissionMask.Modify);
2182 return perms.ToString();
2183 }
2174 } 2184 }
2175} 2185}
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
index 6c56dc3..3b1ab01 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
@@ -1163,16 +1163,14 @@ namespace OpenSim.Region.Framework.Scenes
1163 1163
1164 foreach (TaskInventoryItem item in m_items.Values) 1164 foreach (TaskInventoryItem item in m_items.Values)
1165 { 1165 {
1166 if (item.InvType != (int)InventoryType.Object) 1166 if ((item.CurrentPermissions & item.NextPermissions & (uint)PermissionMask.Copy) == 0)
1167 { 1167 mask &= ~((uint)PermissionMask.Copy >> 13);
1168 if ((item.CurrentPermissions & item.NextPermissions & (uint)PermissionMask.Copy) == 0) 1168 if ((item.CurrentPermissions & item.NextPermissions & (uint)PermissionMask.Transfer) == 0)
1169 mask &= ~((uint)PermissionMask.Copy >> 13); 1169 mask &= ~((uint)PermissionMask.Transfer >> 13);
1170 if ((item.CurrentPermissions & item.NextPermissions & (uint)PermissionMask.Transfer) == 0) 1170 if ((item.CurrentPermissions & item.NextPermissions & (uint)PermissionMask.Modify) == 0)
1171 mask &= ~((uint)PermissionMask.Transfer >> 13); 1171 mask &= ~((uint)PermissionMask.Modify >> 13);
1172 if ((item.CurrentPermissions & item.NextPermissions & (uint)PermissionMask.Modify) == 0) 1172
1173 mask &= ~((uint)PermissionMask.Modify >> 13); 1173 if (item.InvType == (int)InventoryType.Object)
1174 }
1175 else
1176 { 1174 {
1177 if ((item.CurrentPermissions & ((uint)PermissionMask.Copy >> 13)) == 0) 1175 if ((item.CurrentPermissions & ((uint)PermissionMask.Copy >> 13)) == 0)
1178 mask &= ~((uint)PermissionMask.Copy >> 13); 1176 mask &= ~((uint)PermissionMask.Copy >> 13);