Piotr Caban (@piotr) commented about dlls/msvcrt/concurrency.c:
if (pexc->ExceptionRecord->ExceptionCode != CXX_EXCEPTION) return EXCEPTION_CONTINUE_SEARCH;
- cancel_task_collection(data->task_collection);
There's no need to define cancel_task_collection helper. You can call _StructuredTaskCollection__Cancel here.