Thanks Gunnar, suggested changes looks good to me, now merged and submitted to svn/trunk.
On 6 October 2011 09:28, per gunnar holm <[email protected]> wrote: > Hi, > > After upgrading from 2.8.3 to 3.0.1 we experienced a lock in the Mutex > functionality when using Terrain::setVerticalScale. This was caused by > the following call sequence resulting in a lockup: > > void Terrain::setVerticalScale(float scale) > CALLS dirtyRegisteredTiles(); > > > void Terrain::dirtyRegisteredTiles(int dirtyMask) > SETS LOCK OpenThreads::ScopedLock<OpenThreads::Mutex> lock(_mutex); > and CALLS (on every tile) setDirtyMask(dirtyMask); > > > void TerrainTile::setDirtyMask(int dirtyMask) > CALLS _terrain->updateTerrainTileOnNextFrame(this); > > > void Terrain::updateTerrainTileOnNextFrame(TerrainTile* terrainTile) > SETS LOCK OpenThreads::ScopedLock<OpenThreads::Mutex> lock(_mutex); > ******* PROBLEM - since lock has already been set! ******** > > > The suggested fix submitted changes from using Mutex to ReentrantMutex. > > Best Regards, > > -- Gunnar > ------------------------------------------------------------------- > Per Gunnar Holm WeatherOne > Email: [email protected] URL: http://www.weatherone.tv > Phone: +47 22797030 Fax: +47 22797034 > > -- > This email was Anti Virus checked by Astaro Security Gateway. > http://www.astaro.com > > _______________________________________________ > osg-submissions mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org > _______________________________________________ osg-submissions mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org
