aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorDiva Canto2010-06-27 13:07:44 -0700
committerDiva Canto2010-06-27 13:07:44 -0700
commita61d817978f0c6159fcd5df3a2d847ed68946a21 (patch)
tree3292c05fdc312ce2d6c8377a8a931562c952fc0c
parentFixed Robust.32BitLaunch.exe (diff)
parentFix more perms weirdness. Preserve "Locked" status across gives and rez/take. (diff)
downloadopensim-SC-a61d817978f0c6159fcd5df3a2d847ed68946a21.zip
opensim-SC-a61d817978f0c6159fcd5df3a2d847ed68946a21.tar.gz
opensim-SC-a61d817978f0c6159fcd5df3a2d847ed68946a21.tar.bz2
opensim-SC-a61d817978f0c6159fcd5df3a2d847ed68946a21.tar.xz
Merge branch 'master' of ssh://opensimulator.org/var/git/opensim
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.Inventory.cs23
1 files changed, 12 insertions, 11 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
index 64bdc99..9278164 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
@@ -385,9 +385,9 @@ namespace OpenSim.Region.Framework.Scenes
385 if (Permissions.PropagatePermissions() && recipient != senderId) 385 if (Permissions.PropagatePermissions() && recipient != senderId)
386 { 386 {
387 // First, make sore base is limited to the next perms 387 // First, make sore base is limited to the next perms
388 itemCopy.BasePermissions = item.BasePermissions & item.NextPermissions; 388 itemCopy.BasePermissions = item.BasePermissions & (item.NextPermissions | (uint)PermissionMask.Move);
389 // By default, current equals base 389 // By default, current equals base
390 itemCopy.CurrentPermissions = itemCopy.BasePermissions; 390 itemCopy.CurrentPermissions = itemCopy.BasePermissions & item.CurrentPermissions;
391 391
392 // If this is an object, replace current perms 392 // If this is an object, replace current perms
393 // with folded perms 393 // with folded perms
@@ -398,7 +398,7 @@ namespace OpenSim.Region.Framework.Scenes
398 } 398 }
399 399
400 // Ensure there is no escalation 400 // Ensure there is no escalation
401 itemCopy.CurrentPermissions &= item.NextPermissions; 401 itemCopy.CurrentPermissions &= (item.NextPermissions | (uint)PermissionMask.Move);
402 402
403 // Need slam bit on xfer 403 // Need slam bit on xfer
404 itemCopy.CurrentPermissions |= 8; 404 itemCopy.CurrentPermissions |= 8;
@@ -897,14 +897,15 @@ namespace OpenSim.Region.Framework.Scenes
897 897
898 if ((part.OwnerID != destAgent) && Permissions.PropagatePermissions()) 898 if ((part.OwnerID != destAgent) && Permissions.PropagatePermissions())
899 { 899 {
900 agentItem.BasePermissions = taskItem.BasePermissions & taskItem.NextPermissions; 900 agentItem.BasePermissions = taskItem.BasePermissions & (taskItem.NextPermissions | (uint)PermissionMask.Move);
901 if (taskItem.InvType == (int)InventoryType.Object) 901 if (taskItem.InvType == (int)InventoryType.Object)
902 agentItem.CurrentPermissions = agentItem.BasePermissions & ((taskItem.CurrentPermissions & 7) << 13); 902 agentItem.CurrentPermissions = agentItem.BasePermissions & (((taskItem.CurrentPermissions & 7) << 13) | (taskItem.CurrentPermissions & (uint)PermissionMask.Move));
903 agentItem.CurrentPermissions = agentItem.BasePermissions ; 903 else
904 agentItem.CurrentPermissions = agentItem.BasePermissions & taskItem.CurrentPermissions;
904 905
905 agentItem.CurrentPermissions |= 8; 906 agentItem.CurrentPermissions |= 8;
906 agentItem.NextPermissions = taskItem.NextPermissions; 907 agentItem.NextPermissions = taskItem.NextPermissions;
907 agentItem.EveryOnePermissions = taskItem.EveryonePermissions & taskItem.NextPermissions; 908 agentItem.EveryOnePermissions = taskItem.EveryonePermissions & (taskItem.NextPermissions | (uint)PermissionMask.Move);
908 agentItem.GroupPermissions = taskItem.GroupPermissions & taskItem.NextPermissions; 909 agentItem.GroupPermissions = taskItem.GroupPermissions & taskItem.NextPermissions;
909 } 910 }
910 else 911 else
@@ -1086,13 +1087,13 @@ namespace OpenSim.Region.Framework.Scenes
1086 if (Permissions.PropagatePermissions()) 1087 if (Permissions.PropagatePermissions())
1087 { 1088 {
1088 destTaskItem.CurrentPermissions = srcTaskItem.CurrentPermissions & 1089 destTaskItem.CurrentPermissions = srcTaskItem.CurrentPermissions &
1089 srcTaskItem.NextPermissions; 1090 (srcTaskItem.NextPermissions | (uint)PermissionMask.Move);
1090 destTaskItem.GroupPermissions = srcTaskItem.GroupPermissions & 1091 destTaskItem.GroupPermissions = srcTaskItem.GroupPermissions &
1091 srcTaskItem.NextPermissions; 1092 (srcTaskItem.NextPermissions | (uint)PermissionMask.Move);
1092 destTaskItem.EveryonePermissions = srcTaskItem.EveryonePermissions & 1093 destTaskItem.EveryonePermissions = srcTaskItem.EveryonePermissions &
1093 srcTaskItem.NextPermissions; 1094 (srcTaskItem.NextPermissions | (uint)PermissionMask.Move);
1094 destTaskItem.BasePermissions = srcTaskItem.BasePermissions & 1095 destTaskItem.BasePermissions = srcTaskItem.BasePermissions &
1095 srcTaskItem.NextPermissions; 1096 (srcTaskItem.NextPermissions | (uint)PermissionMask.Move);
1096 destTaskItem.CurrentPermissions |= 8; // Slam! 1097 destTaskItem.CurrentPermissions |= 8; // Slam!
1097 } 1098 }
1098 } 1099 }