mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-11-26 22:23:08 +00:00
4b202f4faf
LSan wants to be able to register atfork handlers at __lsan_init time, which can happen either at the first intercepted function call or in a .preinit_array function. Both of these end up being very early in rtld and executed with the bind lock held, which ends up causing problems when we go to _libpthread_init(). Instead of requiring libpthread to be initialized, just insert the new atfork handler straight into the list if it's not ready yet. The critical section and locking should not be necessary if we're really executing this early, as there won't be any threads to contend with. Reviewed by: kib (earlier version), markj Differential Revision: https://reviews.freebsd.org/D47349 |
||
---|---|---|
.. | ||
dlopen | ||
atfork_test.c | ||
Makefile | ||
Makefile.depend | ||
pthread_sigqueue_test.c | ||
umtx_op_test.c |