summaryrefslogtreecommitdiff
path: root/compat/time32/pthread_timedjoin_np_time32.c
diff options
context:
space:
mode:
Diffstat (limited to 'compat/time32/pthread_timedjoin_np_time32.c')
-rw-r--r--compat/time32/pthread_timedjoin_np_time32.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/compat/time32/pthread_timedjoin_np_time32.c b/compat/time32/pthread_timedjoin_np_time32.c
new file mode 100644
index 00000000..3ec29951
--- /dev/null
+++ b/compat/time32/pthread_timedjoin_np_time32.c
@@ -0,0 +1,10 @@
+#define _GNU_SOURCE
+#include "time32.h"
+#include <time.h>
+#include <pthread.h>
+
+int __pthread_timedjoin_np_time32(pthread_t t, void **res, const struct timespec32 *at32)
+{
+ return pthread_timedjoin_np(t, res, !at32 ? 0 : (&(struct timespec){
+ .tv_sec = at32->tv_sec, .tv_nsec = at32->tv_nsec}));
+}