From f6d4d73abd986fbd89918fa8bbbb82746ee08371 Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Sun, 21 Aug 2022 14:04:52 +0900 Subject: Use `rb_fork` to suppress deprecated-declarations warnings --- mjit.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'mjit.c') diff --git a/mjit.c b/mjit.c index e519a3091d..a873b3d9f8 100644 --- a/mjit.c +++ b/mjit.c @@ -76,6 +76,7 @@ #include "internal/cont.h" #include "internal/file.h" #include "internal/hash.h" +#include "internal/process.h" #include "internal/warnings.h" #include "vm_sync.h" #include "ractor_core.h" @@ -747,7 +748,7 @@ start_mjit_compact(struct rb_mjit_unit *unit) rb_vm_t *vm = GET_VM(); rb_native_mutex_lock(&vm->waitpid_lock); - pid_t pid = fork(); + pid_t pid = rb_fork(); if (pid == 0) { rb_native_mutex_unlock(&vm->waitpid_lock); @@ -910,7 +911,7 @@ start_mjit_compile(struct rb_mjit_unit *unit) rb_vm_t *vm = GET_VM(); rb_native_mutex_lock(&vm->waitpid_lock); - pid_t pid = fork(); + pid_t pid = rb_fork(); if (pid == 0) { rb_native_mutex_unlock(&vm->waitpid_lock); -- cgit v1.2.3