summaryrefslogtreecommitdiffstats
path: root/lib/libkse/thread/thr_select.c
diff options
context:
space:
mode:
authorbrian <brian@FreeBSD.org>2005-09-24 01:19:53 +0000
committerbrian <brian@FreeBSD.org>2005-09-24 01:19:53 +0000
commit07adfc3d98d69f8a0bc6828588bde6785f3d08b4 (patch)
tree9cfd706f8848e787805d497398e496a7fcaf985f /lib/libkse/thread/thr_select.c
parent0b524fa9c8ccacdec0c6299d368e15d2a78e83a7 (diff)
downloadFreeBSD-src-07adfc3d98d69f8a0bc6828588bde6785f3d08b4.zip
FreeBSD-src-07adfc3d98d69f8a0bc6828588bde6785f3d08b4.tar.gz
Modify the code path of the ifdef NOTYET part of _kse_single_thread():
o Don't reinitialise the atfork() handler list in the child. We are meant to call the child handler, and on subsequent fork()s should call all three functions as normal. o Don't reinitialise the thread specific keyed data in the child after a fork. Applications may require this for context. o Reinitialise curthread->tlflags after removing ourselves from (and reinitialising) the various internal thread lists. o Reinitialise __malloc_lock in the child after fork() (to balance our explicitly taking the lock prior to the fork()). With these changes, it is possible to enable the NOTYET code in thr_kern.c to allow the use of non-async-safe functions after fork()ing from a threaded program. Reviewed by: Daniel Eischen <deischen@freebsd.org> [_malloc_lock reinitialisation has since been moved to avoid polluting the !NOTYET code]
Diffstat (limited to 'lib/libkse/thread/thr_select.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud