summaryrefslogtreecommitdiff
path: root/thread.h
diff options
context:
space:
mode:
Diffstat (limited to 'thread.h')
-rw-r--r--thread.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/thread.h b/thread.h
index c76534fe3e..8f475a0b7c 100644
--- a/thread.h
+++ b/thread.h
@@ -306,8 +306,12 @@ void Perl_atfork_lock(void);
void Perl_atfork_unlock(void);
#ifndef PTHREAD_ATFORK
-# define PTHREAD_ATFORK(prepare,parent,child) \
- pthread_atfork(prepare,parent,child)
+# ifdef HAS_PTHREAD_ATFORK
+# define PTHREAD_ATFORK(prepare,parent,child) \
+ pthread_atfork(prepare,parent,child)
+# else
+# define PTHREAD_ATFORK(prepare,parent,child)
+# endif
#endif
#ifndef THREAD_RET_TYPE