diff options
author | mingchen | 2008-05-13 21:27:53 +0000 |
---|---|---|
committer | mingchen | 2008-05-13 21:27:53 +0000 |
commit | fe6c626501a187c01e964e685d0e6474a5617786 (patch) | |
tree | 27c6124fca8911544542237d0a39504d37f68479 /OpenSim/Region/Environment | |
parent | * Refactor: Remove locking from InnerScene.GetScenePresence() (diff) | |
download | opensim-SC-fe6c626501a187c01e964e685d0e6474a5617786.zip opensim-SC-fe6c626501a187c01e964e685d0e6474a5617786.tar.gz opensim-SC-fe6c626501a187c01e964e685d0e6474a5617786.tar.bz2 opensim-SC-fe6c626501a187c01e964e685d0e6474a5617786.tar.xz |
*Locked objects now delete after accepting warning as expected
Diffstat (limited to 'OpenSim/Region/Environment')
-rw-r--r-- | OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs b/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs index cead2d8..599e846 100644 --- a/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs +++ b/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs | |||
@@ -364,7 +364,7 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions | |||
364 | return objectFlagsMask; | 364 | return objectFlagsMask; |
365 | } | 365 | } |
366 | 366 | ||
367 | protected bool GenericObjectPermission(LLUUID currentUser, LLUUID objId) | 367 | protected bool GenericObjectPermission(LLUUID currentUser, LLUUID objId, bool denyOnLocked) |
368 | { | 368 | { |
369 | // Default: deny | 369 | // Default: deny |
370 | bool permission = false; | 370 | bool permission = false; |
@@ -394,7 +394,7 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions | |||
394 | // Nobody but the object owner can set permissions on an object | 394 | // Nobody but the object owner can set permissions on an object |
395 | // | 395 | // |
396 | 396 | ||
397 | if (locked && (!IsAdministrator(currentUser))) | 397 | if (locked && (!IsAdministrator(currentUser)) && denyOnLocked) |
398 | { | 398 | { |
399 | return false; | 399 | return false; |
400 | } | 400 | } |
@@ -528,7 +528,7 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions | |||
528 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); | 528 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); |
529 | if (m_bypassPermissions) return m_bypassPermissionsValue; | 529 | if (m_bypassPermissions) return m_bypassPermissionsValue; |
530 | 530 | ||
531 | if (!GenericObjectPermission(owner, objectID)) | 531 | if (!GenericObjectPermission(owner, objectID, true)) |
532 | { | 532 | { |
533 | //They can't even edit the object | 533 | //They can't even edit the object |
534 | return false; | 534 | return false; |
@@ -542,7 +542,7 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions | |||
542 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); | 542 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); |
543 | if (m_bypassPermissions) return m_bypassPermissionsValue; | 543 | if (m_bypassPermissions) return m_bypassPermissionsValue; |
544 | 544 | ||
545 | return GenericObjectPermission(objectID, deleter); | 545 | return GenericObjectPermission(objectID, deleter, false); |
546 | } | 546 | } |
547 | 547 | ||
548 | private bool CanEditObject(LLUUID objectID, LLUUID editorID, Scene scene) | 548 | private bool CanEditObject(LLUUID objectID, LLUUID editorID, Scene scene) |
@@ -551,7 +551,7 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions | |||
551 | if (m_bypassPermissions) return m_bypassPermissionsValue; | 551 | if (m_bypassPermissions) return m_bypassPermissionsValue; |
552 | 552 | ||
553 | 553 | ||
554 | return GenericObjectPermission(editorID, objectID); | 554 | return GenericObjectPermission(editorID, objectID, true); |
555 | } | 555 | } |
556 | 556 | ||
557 | private bool CanEditParcel(LLUUID user, ILandObject parcel, Scene scene) | 557 | private bool CanEditParcel(LLUUID user, ILandObject parcel, Scene scene) |
@@ -600,7 +600,7 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions | |||
600 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); | 600 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); |
601 | if (m_bypassPermissions) return m_bypassPermissionsValue; | 601 | if (m_bypassPermissions) return m_bypassPermissionsValue; |
602 | 602 | ||
603 | bool permission = GenericObjectPermission(moverID, objectID); | 603 | bool permission = GenericObjectPermission(moverID, objectID, true); |
604 | if (!permission) | 604 | if (!permission) |
605 | { | 605 | { |
606 | if (!m_scene.Entities.ContainsKey(objectID)) | 606 | if (!m_scene.Entities.ContainsKey(objectID)) |
@@ -724,7 +724,7 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions | |||
724 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); | 724 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); |
725 | if (m_bypassPermissions) return m_bypassPermissionsValue; | 725 | if (m_bypassPermissions) return m_bypassPermissionsValue; |
726 | 726 | ||
727 | return GenericObjectPermission(returnerID, objectID); | 727 | return GenericObjectPermission(returnerID, objectID, false); |
728 | } | 728 | } |
729 | 729 | ||
730 | private bool CanRezObject(int objectCount, LLUUID owner, LLVector3 objectPosition, Scene scene) | 730 | private bool CanRezObject(int objectCount, LLUUID owner, LLVector3 objectPosition, Scene scene) |
@@ -786,7 +786,7 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions | |||
786 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); | 786 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); |
787 | if (m_bypassPermissions) return m_bypassPermissionsValue; | 787 | if (m_bypassPermissions) return m_bypassPermissionsValue; |
788 | 788 | ||
789 | return GenericObjectPermission(stealer,objectID); | 789 | return GenericObjectPermission(stealer,objectID, false); |
790 | } | 790 | } |
791 | 791 | ||
792 | private bool CanTakeCopyObject(LLUUID objectID, LLUUID userID, Scene inScene) | 792 | private bool CanTakeCopyObject(LLUUID objectID, LLUUID userID, Scene inScene) |
@@ -794,7 +794,7 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions | |||
794 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); | 794 | DebugPermissionInformation(MethodInfo.GetCurrentMethod().Name); |
795 | if (m_bypassPermissions) return m_bypassPermissionsValue; | 795 | if (m_bypassPermissions) return m_bypassPermissionsValue; |
796 | 796 | ||
797 | bool permission = GenericObjectPermission(userID, objectID); | 797 | bool permission = GenericObjectPermission(userID, objectID,false); |
798 | if (permission) | 798 | if (permission) |
799 | { | 799 | { |
800 | if (!m_scene.Entities.ContainsKey(objectID)) | 800 | if (!m_scene.Entities.ContainsKey(objectID)) |