diff options
author | Andrey Kleshchev <117672381+akleshchev@users.noreply.github.com> | 2025-08-06 18:41:52 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-08-06 18:41:52 +0300 |
commit | 55f1c8b9797836c9816528bb5b772eb83b083b50 (patch) | |
tree | fdbc5a913c62265f95e610819637e096f0f85339 /indra/llcommon/workqueue.cpp | |
parent | 514b658fde13bb0c0ec862b081eeebf47bace70d (diff) | |
parent | ce9d66cdd18c58c3b26fbebde633ae00732d7f9f (diff) |
Merge pull request #4492 Merge Develop into Maint-C (2025.06)
Merge Develop into Maint-C (2025.06)
Diffstat (limited to 'indra/llcommon/workqueue.cpp')
-rw-r--r-- | indra/llcommon/workqueue.cpp | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/indra/llcommon/workqueue.cpp b/indra/llcommon/workqueue.cpp index 0eb20323ad..7efaebd569 100644 --- a/indra/llcommon/workqueue.cpp +++ b/indra/llcommon/workqueue.cpp @@ -210,14 +210,22 @@ void LL::WorkQueueBase::callWork(const Work& work) } catch (...) { - // Stash any other kind of uncaught exception to be rethrown by main thread. - LL_WARNS("LLCoros") << "Capturing and rethrowing uncaught exception in WorkQueueBase " - << getKey() << LL_ENDL; - - LL::WorkQueue::ptr_t main_queue = LL::WorkQueue::getInstance("mainloop"); - main_queue->post( - // Bind the current exception, rethrow it in main loop. - [exc = std::current_exception()]() { std::rethrow_exception(exc); }); + if (getKey() != "mainloop") + { + // Stash any other kind of uncaught exception to be rethrown by main thread. + LL_WARNS("LLCoros") << "Capturing and rethrowing uncaught exception in WorkQueueBase " + << getKey() << LL_ENDL; + + LL::WorkQueue::ptr_t main_queue = LL::WorkQueue::getInstance("mainloop"); + main_queue->post( + // Bind the current exception, rethrow it in main loop. + [exc = std::current_exception()]() { std::rethrow_exception(exc); }); + } + else + { + // let main loop crash + throw; + } } #endif // else LL_WINDOWS } |