From daa07d031c6c18c8401457c84ef14d722c97f643 Mon Sep 17 00:00:00 2001 From: Shyotl Date: Sat, 12 Oct 2013 12:13:58 -0500 Subject: [PATCH 1/3] Fixed a couple of compilation errors when using GCC. --- indra/llaudio/llaudioengine.cpp | 5 ----- indra/llaudio/llaudioengine_fmodex.cpp | 4 ++-- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/indra/llaudio/llaudioengine.cpp b/indra/llaudio/llaudioengine.cpp index 62a804f9b..19d37c131 100644 --- a/indra/llaudio/llaudioengine.cpp +++ b/indra/llaudio/llaudioengine.cpp @@ -277,11 +277,6 @@ void LLAudioEngine::updateChannels() } } llassert(found_buffer); - if(!mChannels[i]->mCurrentBufferp->mInUse) - { - llassert(!mChannels[i]->isPlaying()); - llassert(!mChannels[i]->isWaiting()); - } } #endif //SHOW_ASSERT } diff --git a/indra/llaudio/llaudioengine_fmodex.cpp b/indra/llaudio/llaudioengine_fmodex.cpp index deb27e11d..0c297494d 100644 --- a/indra/llaudio/llaudioengine_fmodex.cpp +++ b/indra/llaudio/llaudioengine_fmodex.cpp @@ -178,7 +178,7 @@ public: } void removeChannel(FMOD::Channel* channel) { - gSoundCheck.assertActiveState(channel,true); + assertActiveState(channel,true); active_channels_t::const_iterator it = mActiveChannels.find(channel); llassert(it != mActiveChannels.end()); @@ -208,7 +208,7 @@ public: if(try_log && sVerboseDebugging) #endif { - CFMODSoundChecks::STATUS chan = gSoundCheck.getPtrStatus(ptr); + CFMODSoundChecks::STATUS chan = getPtrStatus(ptr); if(try_log && sVerboseDebugging) { if(active) From 1df09dec358af6b93028fefe941a512cc2883fb5 Mon Sep 17 00:00:00 2001 From: Aleric Inglewood Date: Sat, 12 Oct 2013 21:48:51 +0200 Subject: [PATCH 2/3] Remove assert that 100% reproducible fired - stopping me from logging in. I wanted to fix the problem, but: [21:45] Talking about dense - you guys want this to be fixed or not??? [21:45] no --- indra/newview/llface.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/indra/newview/llface.cpp b/indra/newview/llface.cpp index 15e887519..17ac4ef1a 100644 --- a/indra/newview/llface.cpp +++ b/indra/newview/llface.cpp @@ -791,9 +791,9 @@ BOOL LLFace::genVolumeBBoxes(const LLVolume &volume, S32 f, // Catch potential badness from normalization before it happens // - llassert(mat_normal.mMatrix[0].isFinite3() && (mat_normal.mMatrix[0].dot3(mat_normal.mMatrix[0]).getF32() > F_APPROXIMATELY_ZERO)); - llassert(mat_normal.mMatrix[1].isFinite3() && (mat_normal.mMatrix[1].dot3(mat_normal.mMatrix[1]).getF32() > F_APPROXIMATELY_ZERO)); - llassert(mat_normal.mMatrix[2].isFinite3() && (mat_normal.mMatrix[2].dot3(mat_normal.mMatrix[2]).getF32() > F_APPROXIMATELY_ZERO)); + //llassert(mat_normal.mMatrix[0].isFinite3() && (mat_normal.mMatrix[0].dot3(mat_normal.mMatrix[0]).getF32() > F_APPROXIMATELY_ZERO)); + //llassert(mat_normal.mMatrix[1].isFinite3() && (mat_normal.mMatrix[1].dot3(mat_normal.mMatrix[1]).getF32() > F_APPROXIMATELY_ZERO)); + //llassert(mat_normal.mMatrix[2].isFinite3() && (mat_normal.mMatrix[2].dot3(mat_normal.mMatrix[2]).getF32() > F_APPROXIMATELY_ZERO)); mat_normal.mMatrix[0].normalize3fast(); mat_normal.mMatrix[1].normalize3fast(); From 1389bf76ce3182f072d12ac8bc008fc4b336e4b6 Mon Sep 17 00:00:00 2001 From: Aleric Inglewood Date: Sat, 12 Oct 2013 22:36:27 +0200 Subject: [PATCH 3/3] Bug fix. --- indra/llaudio/llaudioengine.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/indra/llaudio/llaudioengine.cpp b/indra/llaudio/llaudioengine.cpp index 62a804f9b..72351dd5a 100644 --- a/indra/llaudio/llaudioengine.cpp +++ b/indra/llaudio/llaudioengine.cpp @@ -328,7 +328,7 @@ void LLAudioEngine::idle(F32 max_decode_time) //Also add sources that might be able to start playing to a priority queue. //Only sources without channels, or are waiting for a syncmaster, should be added to this queue. std::priority_queue >,SourcePriorityComparator> queue; - for (source_map::iterator iter = mAllSources.begin(); iter != mAllSources.end(); ++iter) + for (source_map::iterator iter = mAllSources.begin(); iter != mAllSources.end();) { LLAudioSource *sourcep = iter->second; @@ -344,6 +344,9 @@ void LLAudioEngine::idle(F32 max_decode_time) continue; } + // Increment iter here (it is not used anymore), so we can use continue below to move on to the next source. + ++iter; + LLAudioData *adp = sourcep->getCurrentData(); //If there is no current data at all, or if it hasn't loaded, we must skip this source. if (!adp || !adp->getBuffer())