diff options
Diffstat (limited to 'OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs')
-rw-r--r-- | OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs b/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs index 95e7456..ba3a7c9 100644 --- a/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs +++ b/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs | |||
@@ -541,16 +541,17 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
541 | 541 | ||
542 | #region Permissions | 542 | #region Permissions |
543 | 543 | ||
544 | private bool CanTakeObject(UUID objectID, UUID stealer, Scene scene) | 544 | private bool CanTakeObject(SceneObjectGroup sog, ScenePresence sp) |
545 | { | 545 | { |
546 | if (m_bypassPermissions) return true; | 546 | if (m_bypassPermissions) return true; |
547 | 547 | ||
548 | if (!m_OutboundPermission && !UserManagementModule.IsLocalGridUser(stealer)) | 548 | if(sp == null || sog == null) |
549 | return false; | ||
550 | |||
551 | if (!m_OutboundPermission && !UserManagementModule.IsLocalGridUser(sp.UUID)) | ||
549 | { | 552 | { |
550 | SceneObjectGroup sog = null; | 553 | if (sog.OwnerID == sp.UUID) |
551 | if (m_Scene.TryGetSceneObjectGroup(objectID, out sog) && sog.OwnerID == stealer) | ||
552 | return true; | 554 | return true; |
553 | |||
554 | return false; | 555 | return false; |
555 | } | 556 | } |
556 | 557 | ||