From 860b2a502f797e5822c6705d4639f370f3ac5861 Mon Sep 17 00:00:00 2001 From: John Hurliman Date: Thu, 16 Sep 2010 17:30:46 -0700 Subject: Changed SceneObjectGroup to store parts with the fast and thread-safe MapAndArray collection --- .../ContentManagementSystem/CMEntityCollection.cs | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) (limited to 'OpenSim/Region/OptionalModules/ContentManagementSystem/CMEntityCollection.cs') diff --git a/OpenSim/Region/OptionalModules/ContentManagementSystem/CMEntityCollection.cs b/OpenSim/Region/OptionalModules/ContentManagementSystem/CMEntityCollection.cs index d21b652..7f64ebd 100644 --- a/OpenSim/Region/OptionalModules/ContentManagementSystem/CMEntityCollection.cs +++ b/OpenSim/Region/OptionalModules/ContentManagementSystem/CMEntityCollection.cs @@ -121,19 +121,16 @@ namespace OpenSim.Region.OptionalModules.ContentManagement continue; temp = (SceneObjectGroup) currObj; - lock (temp.Children) + if (m_CMEntityHash.ContainsKey(temp.UUID)) { - if (m_CMEntityHash.ContainsKey(temp.UUID)) - { - foreach (SceneObjectPart part in temp.Children.Values) - if (!((ContentManagementEntity)m_CMEntityHash[temp.UUID]).HasChildPrim(part.UUID)) - missingList.Add(part); - } - else //Entire group is missing from revision. (and is a new part in region) - { - foreach (SceneObjectPart part in temp.Children.Values) + foreach (SceneObjectPart part in temp.Parts) + if (!((ContentManagementEntity)m_CMEntityHash[temp.UUID]).HasChildPrim(part.UUID)) missingList.Add(part); - } + } + else //Entire group is missing from revision. (and is a new part in region) + { + foreach (SceneObjectPart part in temp.Parts) + missingList.Add(part); } } return missingList; -- cgit v1.1