mirror of
https://github.com/opensim/opensim.git
synced 2026-08-01 14:16:07 +08:00
Deep copy the collection of at_target objects so it can't be modified while
it's being iterated
This commit is contained in:
@@ -1692,9 +1692,12 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
|
||||
private void CheckAtTargets()
|
||||
{
|
||||
Dictionary<UUID, SceneObjectGroup>.ValueCollection objs;
|
||||
List<SceneObjectGroup> objs = new List<SceneObjectGroup>();
|
||||
lock (m_groupsWithTargets)
|
||||
objs = m_groupsWithTargets.Values;
|
||||
{
|
||||
foreach (SceneObjectGroup grp in m_groupsWithTargets.Values)
|
||||
objs.Add(grp);
|
||||
}
|
||||
|
||||
foreach (SceneObjectGroup entry in objs)
|
||||
entry.checkAtTargets();
|
||||
|
||||
Reference in New Issue
Block a user