Commit 1220b3b7 authored by Fabrice Fontaine's avatar Fabrice Fontaine

Remove usage of __register_atfork

Calling an internal function of glibc is never a good idea.
This is especially true for __register_atfork which is not defined on
uClibc with noMMU.
So remove call to __register_atfork and so always use pthread_atfork
Signed-off-by: Fabrice Fontaine's avatarFabrice Fontaine <fontaine.fabrice@gmail.com>
parent 7cfa2d45
Pipeline #5250 failed with stage
in 58 seconds
......@@ -31,14 +31,7 @@
static pthread_mutex_t arc4random_mtx = PTHREAD_MUTEX_INITIALIZER;
#define _ARC4_LOCK() pthread_mutex_lock(&arc4random_mtx)
#define _ARC4_UNLOCK() pthread_mutex_unlock(&arc4random_mtx)
#ifdef __GLIBC__
extern void *__dso_handle;
extern int __register_atfork(void (*)(void), void(*)(void), void (*)(void), void *);
#define _ARC4_ATFORK(f) __register_atfork(NULL, NULL, (f), __dso_handle)
#else
#define _ARC4_ATFORK(f) pthread_atfork(NULL, NULL, (f))
#endif
static inline void
_getentropy_fail(void)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment