]> granicus.if.org Git - gc/commit
Ensure GC initialized when atfork_prepare is called by client
authorIvan Maidanski <ivmai@mail.ru>
Fri, 23 Jun 2017 06:13:15 +0000 (09:13 +0300)
committerIvan Maidanski <ivmai@mail.ru>
Sun, 2 Jul 2017 08:44:10 +0000 (11:44 +0300)
commit9102097451e5cc29ad8ee4974dfc92b3fbcfe2c1
tree38693d37a887ebda4f20d3d5744a335438dc89bd
parentc57860882eccf63d78f8d40e84e4e0098fdf2460
Ensure GC initialized when atfork_prepare is called by client

Otherwise, if THREAD_LOCAL_ALLOC, GC_remove_all_threads_but_me would
not find the current thread descriptor in GC_threads.

* pthread_support.c [CAN_HANDLE_FORK] (GC_atfork_prepare): Call GC_init
if not GC_is_initialized.
* win32_threads.c [CAN_HANDLE_FORK] (GC_atfork_prepare): Likewise.
pthread_support.c
win32_threads.c