diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2018-12-16 14:31:32 -0500 |
---|---|---|
committer | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2022-02-11 20:53:21 +0200 |
commit | 6c3507d6d358485c2a8e2fc4d915847cbeda3ee3 (patch) | |
tree | 447685b69a4098011c70069479cb11ebf47da525 /indra/newview | |
parent | 236593e997e931580d3bd3192b12e450c8054b07 (diff) |
SL-10190: Introduce LLCoros::saveException() and rethrow().
This mechanism uses a queue of std::exception_ptrs to transport an (otherwise)
uncaught exception from a terminated coroutine to the thread's main fiber. The
main loop calls LLCoros::rethrow() just after giving some cycles to ready
coroutines that frame.
# Conflicts:
# indra/llcommon/llcoros.cpp
# indra/llcommon/llcoros.h
# indra/newview/llappviewer.cpp
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llappviewer.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index d17498a6ed..0d80ab543e 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -1471,6 +1471,8 @@ bool LLAppViewer::doFrame() mainloop.post(newFrame); // give listeners a chance to run llcoro::suspend(); + // if one of our coroutines threw an uncaught exception, rethrow it now + LLCoros::instance().rethrow(); if (!LLApp::isExiting()) { |