summaryrefslogtreecommitdiff
path: root/src/thread/thrd_exit.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/thread/thrd_exit.c')
-rw-r--r--src/thread/thrd_exit.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/thread/thrd_exit.c b/src/thread/thrd_exit.c
new file mode 100644
index 00000000..b66bd996
--- /dev/null
+++ b/src/thread/thrd_exit.c
@@ -0,0 +1,9 @@
+#include "pthread_impl.h"
+#include <threads.h>
+
+_Noreturn void __pthread_exit(void *);
+
+_Noreturn void thrd_exit(int result)
+{
+ __pthread_exit((void*)(intptr_t)result);
+}