Fix crash where two scene loop threads could changes m_MeshToTriMeshMap at the same time.
Have to lock m_MeshToTriMeshMap as property is static and with more than one region two scene loops could try to manipulate at the same time.0.7.3-post-fixes
parent
fa30ace67d
commit
64eb4b8408
|
@ -842,6 +842,11 @@ namespace OpenSim.Region.Physics.OdePlugin
|
|||
mesh.getIndexListAsPtrToIntArray(out indices, out triStride, out indexCount); // Also fixed, needs release after usage
|
||||
|
||||
mesh.releaseSourceMeshData(); // free up the original mesh data to save memory
|
||||
|
||||
// We must lock here since m_MeshToTriMeshMap is static and multiple scene threads may call this method at
|
||||
// the same time.
|
||||
lock (m_MeshToTriMeshMap)
|
||||
{
|
||||
if (m_MeshToTriMeshMap.ContainsKey(mesh))
|
||||
{
|
||||
_triMeshData = m_MeshToTriMeshMap[mesh];
|
||||
|
@ -854,6 +859,7 @@ namespace OpenSim.Region.Physics.OdePlugin
|
|||
d.GeomTriMeshDataPreprocess(_triMeshData);
|
||||
m_MeshToTriMeshMap[mesh] = _triMeshData;
|
||||
}
|
||||
}
|
||||
|
||||
// _parent_scene.waitForSpaceUnlock(m_targetSpace);
|
||||
try
|
||||
|
|
Loading…
Reference in New Issue