AsyncBridge: Comment why we don't checkException in loop

This commit is contained in:
2025-10-31 07:59:23 -04:00
parent b65b0f2370
commit 7b830f0a68
+10
View File
@@ -31,6 +31,16 @@ public:
io_service.run_one(); io_service.run_one();
if (isAsyncOperationComplete.load() || io_service.stopped()) if (isAsyncOperationComplete.load() || io_service.stopped())
{ break; } { break; }
/** EXPLANATION:
* In the mrntt and mind thread loops we call checkException() after
* run() returns, but we don't have to do that here because
* setException() calls stop.
*
* So if an exception is set on our thread, we'll break out of this
* loop due to the check for stopped() above, and that'll take us
* back out to the main loop, where we'll catch the exception.
*/
} }
} }