diff options
| author | Sharon Rosner <sharon@noteflakes.com> | 2025-12-05 06:20:39 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-12-05 18:20:39 +1300 |
| commit | 5f6b31c23ff1eefdf3cd5807ce5f80abf24eb1b2 (patch) | |
| tree | 9736faf696a6d55ce8803cc5e5d14dea6c4d98cf /thread.c | |
| parent | e822209d3e3dfde39a7d6818951869606ae8cbf0 (diff) | |
Correctly handle `Process.fork` with an active `Fiber.scheduler`. (#15385)
In the child process, nullify the current fiber scheduler and set the current fiber to blocking.
Diffstat (limited to 'thread.c')
| -rw-r--r-- | thread.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -4997,6 +4997,7 @@ rb_thread_atfork(void) rb_threadptr_pending_interrupt_clear(th); rb_thread_atfork_internal(th, terminate_atfork_i); th->join_list = NULL; + th->scheduler = Qnil; rb_fiber_atfork(th); /* We don't want reproduce CVE-2003-0900. */ |
