aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Environment')
-rw-r--r--OpenSim/Region/Environment/Modules/World/Land/LandManagementModule.cs12
-rw-r--r--OpenSim/Region/Environment/Scenes/InnerScene.cs1
2 files changed, 9 insertions, 4 deletions
diff --git a/OpenSim/Region/Environment/Modules/World/Land/LandManagementModule.cs b/OpenSim/Region/Environment/Modules/World/Land/LandManagementModule.cs
index 29e3143..1c04796 100644
--- a/OpenSim/Region/Environment/Modules/World/Land/LandManagementModule.cs
+++ b/OpenSim/Region/Environment/Modules/World/Land/LandManagementModule.cs
@@ -583,11 +583,17 @@ namespace OpenSim.Region.Environment.Modules.World.Land
583 public void UpdateLandPrimCounts() 583 public void UpdateLandPrimCounts()
584 { 584 {
585 ResetAllLandPrimCounts(); 585 ResetAllLandPrimCounts();
586 foreach (EntityBase obj in m_scene.Entities.Values) 586 lock (m_scene.Entities)
587 { 587 {
588 if (obj is SceneObjectGroup) 588 foreach (EntityBase obj in m_scene.Entities.Values)
589 { 589 {
590 m_scene.EventManager.TriggerParcelPrimCountAdd((SceneObjectGroup)obj); 590 if (obj != null)
591 {
592 if (obj is SceneObjectGroup)
593 {
594 m_scene.EventManager.TriggerParcelPrimCountAdd((SceneObjectGroup)obj);
595 }
596 }
591 } 597 }
592 } 598 }
593 FinalizeLandPrimCountUpdate(); 599 FinalizeLandPrimCountUpdate();
diff --git a/OpenSim/Region/Environment/Scenes/InnerScene.cs b/OpenSim/Region/Environment/Scenes/InnerScene.cs
index 589d642..f04ce7f 100644
--- a/OpenSim/Region/Environment/Scenes/InnerScene.cs
+++ b/OpenSim/Region/Environment/Scenes/InnerScene.cs
@@ -234,7 +234,6 @@ namespace OpenSim.Region.Environment.Scenes
234 { 234 {
235 if (Entities.ContainsKey(uuid)) 235 if (Entities.ContainsKey(uuid))
236 { 236 {
237 Console.WriteLine("REMOVED " + ((SceneObjectGroup)Entities[uuid]).Children.Count + "!");
238 if (!resultOfObjectLinked) 237 if (!resultOfObjectLinked)
239 { 238 {
240 m_numPrim -= ((SceneObjectGroup)Entities[uuid]).Children.Count; 239 m_numPrim -= ((SceneObjectGroup)Entities[uuid]).Children.Count;