aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorMelanie2012-10-28 18:41:47 +0000
committerMelanie2012-10-28 18:41:47 +0000
commit5a96ef52cb552c835cc109cb005db989eade5803 (patch)
treee6b249beb93b79562560aed5b306baf6ae9e1277
parentminor: Fix verbose IAR save message to make it a bit clearer that item data i... (diff)
downloadopensim-SC_OLD-5a96ef52cb552c835cc109cb005db989eade5803.zip
opensim-SC_OLD-5a96ef52cb552c835cc109cb005db989eade5803.tar.gz
opensim-SC_OLD-5a96ef52cb552c835cc109cb005db989eade5803.tar.bz2
opensim-SC_OLD-5a96ef52cb552c835cc109cb005db989eade5803.tar.xz
Deep copy the collection of at_target objects so it can't be modified while
it's being iterated
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.cs7
1 files changed, 5 insertions, 2 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs
index 9c61fe7..2cdc4b3 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.cs
@@ -1692,9 +1692,12 @@ namespace OpenSim.Region.Framework.Scenes
1692 1692
1693 private void CheckAtTargets() 1693 private void CheckAtTargets()
1694 { 1694 {
1695 Dictionary<UUID, SceneObjectGroup>.ValueCollection objs; 1695 List<SceneObjectGroup> objs = new List<SceneObjectGroup>();
1696 lock (m_groupsWithTargets) 1696 lock (m_groupsWithTargets)
1697 objs = m_groupsWithTargets.Values; 1697 {
1698 foreach (SceneObjectGroup grp in m_groupsWithTargets.Values)
1699 objs.Add(grp);
1700 }
1698 1701
1699 foreach (SceneObjectGroup entry in objs) 1702 foreach (SceneObjectGroup entry in objs)
1700 entry.checkAtTargets(); 1703 entry.checkAtTargets();