- if (smx_ctx_thread_sem)
- xbt_os_sem_release(smx_ctx_thread_sem);
-
- // Signal to the maestro that it has finished:
- xbt_os_sem_release(this->end_);
-
-#ifndef WIN32
- stack_t stack = {};
- stack.ss_flags = SS_DISABLE;
- sigaltstack(&stack, nullptr);
-#endif
- xbt_os_thread_exit(nullptr);