Lock m_pendingObjects when calling GetPendingObjectsCount().

This is only called by a region console command.
We should also be locking m_partsUpdateQueue when dequeueing the next part, or locking m_pendingObjects in QueuePartForUpdate().
However, I won't do this now since I don't have time to analyze how this would affect liveness.
remove-scene-viewer
Justin Clark-Casey (justincc) 2011-09-06 22:48:05 +01:00
parent 3d4d3427cd
commit e6cd4defdb
1 changed files with 2 additions and 1 deletions

View File

@ -231,7 +231,8 @@ namespace OpenSim.Region.Framework.Scenes
public int GetPendingObjectsCount()
{
if (m_pendingObjects != null)
return m_pendingObjects.Count;
lock (m_pendingObjects)
return m_pendingObjects.Count;
return 0;
}