diff options
Diffstat (limited to 'cont.c')
-rw-r--r-- | cont.c | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -1977,6 +1977,18 @@ fiber_to_s(VALUE fibval) return rb_block_to_s(fibval, &proc->block, status_info); } +#ifdef HAVE_WORKING_FORK +void +rb_fiber_atfork(rb_thread_t *th) +{ + if (&th->root_fiber->cont.saved_ec != th->ec) { + th->root_fiber = th->ec->fiber_ptr; + th->root_fiber->cont.type = ROOT_FIBER_CONTEXT; + } + th->root_fiber->prev = 0; +} +#endif + /* * Document-class: FiberError * |