aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/CoreModules/Scripting/WorldComm/WorldCommModule.cs9
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/Timer.cs5
2 files changed, 10 insertions, 4 deletions
diff --git a/OpenSim/Region/CoreModules/Scripting/WorldComm/WorldCommModule.cs b/OpenSim/Region/CoreModules/Scripting/WorldComm/WorldCommModule.cs
index d4a28e2..60df2e7 100644
--- a/OpenSim/Region/CoreModules/Scripting/WorldComm/WorldCommModule.cs
+++ b/OpenSim/Region/CoreModules/Scripting/WorldComm/WorldCommModule.cs
@@ -602,9 +602,12 @@ namespace OpenSim.Region.CoreModules.Scripting.WorldComm
602 ListenerInfo info = 602 ListenerInfo info =
603 ListenerInfo.FromData(localID, itemID, hostID, item); 603 ListenerInfo.FromData(localID, itemID, hostID, item);
604 604
605 if (!m_listeners.ContainsKey((int)item[2])) 605 lock (m_listeners)
606 m_listeners.Add((int)item[2], new List<ListenerInfo>()); 606 {
607 m_listeners[(int)item[2]].Add(info); 607 if (!m_listeners.ContainsKey((int)item[2]))
608 m_listeners.Add((int)item[2], new List<ListenerInfo>());
609 m_listeners[(int)item[2]].Add(info);
610 }
608 611
609 idx+=6; 612 idx+=6;
610 } 613 }
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/Timer.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/Timer.cs
index 0716d45..eeb59d9 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/Timer.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/Timer.cs
@@ -166,7 +166,10 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Plugins
166 ts.next = DateTime.Now.Ticks + (long)data[idx+1]; 166 ts.next = DateTime.Now.Ticks + (long)data[idx+1];
167 idx += 2; 167 idx += 2;
168 168
169 Timers.Add(MakeTimerKey(localID,itemID), ts); 169 lock (TimerListLock)
170 {
171 Timers.Add(MakeTimerKey(localID, itemID), ts);
172 }
170 } 173 }
171 } 174 }
172 } 175 }