aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
diff options
context:
space:
mode:
authorMelanie Thielker2010-07-14 16:21:55 +0200
committerMelanie2010-07-14 16:12:44 +0100
commit39cd57598bf21c10bf5f187a65d37ba2c07c775b (patch)
treec3c61276f82cba4205caaa7893d106ac7acfa8a8 /OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
parentRevert "More on mantis #4869. This fixes the problem of objects showing up as... (diff)
downloadopensim-SC_OLD-39cd57598bf21c10bf5f187a65d37ba2c07c775b.zip
opensim-SC_OLD-39cd57598bf21c10bf5f187a65d37ba2c07c775b.tar.gz
opensim-SC_OLD-39cd57598bf21c10bf5f187a65d37ba2c07c775b.tar.bz2
opensim-SC_OLD-39cd57598bf21c10bf5f187a65d37ba2c07c775b.tar.xz
Fix a permissions issue
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/Scene.Inventory.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.Inventory.cs15
1 files changed, 11 insertions, 4 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
index 34461dc..2578685 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
@@ -432,10 +432,6 @@ namespace OpenSim.Region.Framework.Scenes
432 (uint)PermissionMask.Move; 432 (uint)PermissionMask.Move;
433 uint ownerPerms = item.CurrentPermissions; 433 uint ownerPerms = item.CurrentPermissions;
434 434
435 // Mask the base permissions. This is a conservative
436 // approach altering only the three main perms
437 basePerms &= nextPerms;
438
439 // If this is an object, root prim perms may be more 435 // If this is an object, root prim perms may be more
440 // permissive than folded perms. Use folded perms as 436 // permissive than folded perms. Use folded perms as
441 // a mask 437 // a mask
@@ -451,10 +447,17 @@ namespace OpenSim.Region.Framework.Scenes
451 447
452 // Mask the owner perms to the folded perms 448 // Mask the owner perms to the folded perms
453 ownerPerms &= foldedPerms; 449 ownerPerms &= foldedPerms;
450 basePerms &= foldedPerms;
454 451
455 // If the root was mod, let the mask reflect that 452 // If the root was mod, let the mask reflect that
453 // We also need to adjust the base here, because
454 // we should be able to edit in-inventory perms
455 // for the root prim, if it's mod.
456 if (isRootMod) 456 if (isRootMod)
457 {
457 ownerPerms |= (uint)PermissionMask.Modify; 458 ownerPerms |= (uint)PermissionMask.Modify;
459 basePerms |= (uint)PermissionMask.Modify;
460 }
458 } 461 }
459 462
460 // These will be applied to the root prim at next rez. 463 // These will be applied to the root prim at next rez.
@@ -462,6 +465,10 @@ namespace OpenSim.Region.Framework.Scenes
462 // are preserved due to the above mangling 465 // are preserved due to the above mangling
463 ownerPerms &= nextPerms; 466 ownerPerms &= nextPerms;
464 467
468 // Mask the base permissions. This is a conservative
469 // approach altering only the three main perms
470 basePerms &= nextPerms;
471
465 // Assign to the actual item. Make sure the slam bit is 472 // Assign to the actual item. Make sure the slam bit is
466 // set, if it wasn't set before. 473 // set, if it wasn't set before.
467 itemCopy.BasePermissions = basePerms; 474 itemCopy.BasePermissions = basePerms;