Fix merge artefacts

avinationmerge
Melanie 2010-11-08 02:58:33 +00:00
parent 18b27408d6
commit 6056ae8d88
1 changed files with 19 additions and 14 deletions

View File

@ -174,6 +174,7 @@ namespace OpenSim.Region.Framework.Scenes
private bool m_firstHeartbeat = true; private bool m_firstHeartbeat = true;
private object m_deleting_scene_object = new object(); private object m_deleting_scene_object = new object();
private object m_cleaningAttachments = new object();
private UpdatePrioritizationSchemes m_priorityScheme = UpdatePrioritizationSchemes.Time; private UpdatePrioritizationSchemes m_priorityScheme = UpdatePrioritizationSchemes.Time;
private bool m_reprioritizationEnabled = true; private bool m_reprioritizationEnabled = true;
@ -4995,11 +4996,14 @@ namespace OpenSim.Region.Framework.Scenes
List<SceneObjectGroup> objectsToDelete = List<SceneObjectGroup> objectsToDelete =
new List<SceneObjectGroup>(); new List<SceneObjectGroup>();
lock (m_cleaningAttachments)
{
ForEachSOG(delegate (SceneObjectGroup grp) ForEachSOG(delegate (SceneObjectGroup grp)
{
if (grp.RootPart.Shape.State != 0)
{ {
if (grp.RootPart.Shape.PCode == 0 && grp.RootPart.Shape.State != 0 && (!objectsToDelete.Contains(grp))) if (grp.RootPart.Shape.PCode == 0 && grp.RootPart.Shape.State != 0 && (!objectsToDelete.Contains(grp)))
{
UUID agentID = grp.OwnerID;
if (agentID == UUID.Zero)
{ {
objectsToDelete.Add(grp); objectsToDelete.Add(grp);
return; return;
@ -5013,6 +5017,7 @@ namespace OpenSim.Region.Framework.Scenes
} }
} }
}); });
}
foreach (SceneObjectGroup grp in objectsToDelete) foreach (SceneObjectGroup grp in objectsToDelete)
{ {