aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/SceneObjectGroup.Inventory.cs
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2012-07-10 22:41:11 +0100
committerJustin Clark-Casey (justincc)2012-07-10 22:41:11 +0100
commitf3134b5cf688af9b824880e0221072b24d22f33e (patch)
tree94ac27ba4fd2f7f0700cc626005d20d7c6465881 /OpenSim/Region/Framework/Scenes/SceneObjectGroup.Inventory.cs
parentIf a script is being stopped manually, then give the scriptpool thread 1 seco... (diff)
downloadopensim-SC_OLD-f3134b5cf688af9b824880e0221072b24d22f33e.zip
opensim-SC_OLD-f3134b5cf688af9b824880e0221072b24d22f33e.tar.gz
opensim-SC_OLD-f3134b5cf688af9b824880e0221072b24d22f33e.tar.bz2
opensim-SC_OLD-f3134b5cf688af9b824880e0221072b24d22f33e.tar.xz
When an attachment is detached to inv or derezzed, stop the scripts, update the known item with script state still in the script engine and then remove the scripts.
This is to fix a regression starting from 5301648 where attachments had to start being deleted before persistence in order to avoid race conditions with hud update threads.
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/SceneObjectGroup.Inventory.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectGroup.Inventory.cs10
1 files changed, 9 insertions, 1 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.Inventory.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.Inventory.cs
index 2866b54..ddf5da0 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.Inventory.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.Inventory.cs
@@ -79,7 +79,7 @@ namespace OpenSim.Region.Framework.Scenes
79 } 79 }
80 80
81 /// <summary> 81 /// <summary>
82 /// Stop the scripts contained in all the prims in this group 82 /// Stop and remove the scripts contained in all the prims in this group
83 /// </summary> 83 /// </summary>
84 /// <param name="sceneObjectBeingDeleted"> 84 /// <param name="sceneObjectBeingDeleted">
85 /// Should be true if these scripts are being removed because the scene 85 /// Should be true if these scripts are being removed because the scene
@@ -93,6 +93,14 @@ namespace OpenSim.Region.Framework.Scenes
93 } 93 }
94 94
95 /// <summary> 95 /// <summary>
96 /// Stop the scripts contained in all the prims in this group
97 /// </summary>
98 public void StopScriptInstances()
99 {
100 Array.ForEach<SceneObjectPart>(m_parts.GetArray(), p => p.Inventory.StopScriptInstances());
101 }
102
103 /// <summary>
96 /// Add an inventory item from a user's inventory to a prim in this scene object. 104 /// Add an inventory item from a user's inventory to a prim in this scene object.
97 /// </summary> 105 /// </summary>
98 /// <param name="agentID">The agent adding the item.</param> 106 /// <param name="agentID">The agent adding the item.</param>