* fork.cc (fork_child): Call the __pthread_atforkchild function.

(fork_parent): Call the __pthread_atforkparent function.
* cygwin.din: Export pthread_atfork.
* thread.h (callback): New class.
(MTinterface): Use it.
* thread.cc (__pthread_atforkprepare): New function.
(__pthread_atforkparent): New function.
(__pthread_atforkchild): New function.
(__pthread_atfork): New function.
* pthread.cc (pthread_atfork): New function.
This commit is contained in:
Christopher Faylor
2001-04-13 15:28:20 +00:00
parent e61cead397
commit 39b6859a28
7 changed files with 163 additions and 4 deletions

View File

@ -29,6 +29,12 @@ pthread_once (pthread_once_t * once_control, void (*init_routine) (void))
return __pthread_once (once_control, init_routine);
}
int
pthread_atfork(void (*prepare)(void), void (*parent)(void), void (*child)(void))
{
return __pthread_atfork(prepare, parent, child);
}
int
pthread_attr_init (pthread_attr_t * attr)
{