File tree Expand file tree Collapse file tree 2 files changed +17
-8
lines changed Expand file tree Collapse file tree 2 files changed +17
-8
lines changed Original file line number Diff line number Diff line change @@ -182,14 +182,22 @@ void LL::WorkQueueBase::callWork(const Work& work)
182
182
}
183
183
catch (...)
184
184
{
185
- // Stash any other kind of uncaught exception to be rethrown by main thread.
186
- LL_WARNS (" LLCoros" ) << " Capturing and rethrowing uncaught exception in WorkQueueBase "
185
+ if (getKey () != " mainloop" )
186
+ {
187
+ // Stash any other kind of uncaught exception to be rethrown by main thread.
188
+ LL_WARNS (" LLCoros" ) << " Capturing and rethrowing uncaught exception in WorkQueueBase "
187
189
<< getKey () << LL_ENDL;
188
-
189
- LL::WorkQueue::ptr_t main_queue = LL::WorkQueue::getInstance (" mainloop" );
190
- main_queue->post (
191
- // Bind the current exception, rethrow it in main loop.
192
- [exc = std::current_exception ()]() { std::rethrow_exception (exc); });
190
+
191
+ LL::WorkQueue::ptr_t main_queue = LL::WorkQueue::getInstance (" mainloop" );
192
+ main_queue->post (
193
+ // Bind the current exception, rethrow it in main loop.
194
+ [exc = std::current_exception ()]() { std::rethrow_exception (exc); });
195
+ }
196
+ else
197
+ {
198
+ // let main loop crash
199
+ throw ;
200
+ }
193
201
}
194
202
#endif // else LL_WINDOWS
195
203
}
Original file line number Diff line number Diff line change @@ -5696,7 +5696,8 @@ void LLAppViewer::forceExceptionThreadCrash()
5696
5696
5697
5697
void run ()
5698
5698
{
5699
- throw std::exception ();
5699
+ const std::string exception_text = " This is a deliberate exception in a thread" ;
5700
+ throw std::runtime_error (exception_text);
5700
5701
}
5701
5702
};
5702
5703
You can’t perform that action at this time.
0 commit comments