diff --git a/indra/llcommon/llcoros.cpp b/indra/llcommon/llcoros.cpp index d16bf0160b..69acc452ee 100644 --- a/indra/llcommon/llcoros.cpp +++ b/indra/llcommon/llcoros.cpp @@ -234,8 +234,16 @@ void LLCoros::toplevel(coro::self& self, CoroData* data, const callable_t& calla { // capture the 'self' param in CoroData data->mSelf = &self; + + // FIRE-19481; do not let any exception propagate + // callable(); + + try { // run the code the caller actually wants in the coroutine callable(); + } catch( ... ){ LL_WARNS() << "Exception during coroutine" << LL_ENDL; } + // + // This cleanup isn't perfectly symmetrical with the way we initially set // data->mPrev, but this is our last chance to reset mCurrentCoro. sCurrentCoro.reset(data->mPrev); diff --git a/indra/llcommon/llevents.cpp b/indra/llcommon/llevents.cpp index d9b0112edb..25b89017cb 100644 --- a/indra/llcommon/llevents.cpp +++ b/indra/llcommon/llevents.cpp @@ -45,6 +45,7 @@ #include // external library headers #include +#include // for abnormal_exit #if LL_WINDOWS #pragma warning (push) #pragma warning (disable : 4701) // compiler thinks might use uninitialized var, but no @@ -512,7 +513,15 @@ bool LLEventStream::post(const LLSD& event) // Let caller know if any one listener handled the event. This is mostly // useful when using LLEventStream as a listener for an upstream // LLEventPump. + + // FIRE-19481; do not let any abnormal_exit propagate + // return (*signal)(event); + + try { return (*signal)(event); + }catch( boost::dcoroutines::abnormal_exit& ) + { return false; } + // } /*****************************************************************************