aboutsummaryrefslogtreecommitdiffstats
path: root/process.c
diff options
context:
space:
mode:
authorMasaki Matsushita <glass.saga@gmail.com>2020-12-07 12:49:44 +0900
committerMasaki Matsushita <glass.saga@gmail.com>2020-12-07 13:33:53 +0900
commit5d8bcc4870601ab1ee05346346f241d4a805aac9 (patch)
treebcc2176902005a12c3b8acd416cc5920deb7e976 /process.c
parent1ba05f5b2d7b1701242023b5ac156b169f1ded90 (diff)
downloadruby-5d8bcc4870601ab1ee05346346f241d4a805aac9.tar.gz
Revert getaddrinfo_a()
getaddrinfo_a() gets stuck after fork(). To avoid this, we need 1 second sleep to wait for internal worker threads of getaddrinfo_a() to be finished, but that is unacceptable. [Bug #17220] [Feature #17134] [Feature #17187]
Diffstat (limited to 'process.c')
-rw-r--r--process.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/process.c b/process.c
index 0542aca2e4..8ad555f8f6 100644
--- a/process.c
+++ b/process.c
@@ -331,9 +331,6 @@ static ID id_CLOCK_BASED_CLOCK_PROCESS_CPUTIME_ID;
static ID id_MACH_ABSOLUTE_TIME_BASED_CLOCK_MONOTONIC;
#endif
static ID id_hertz;
-#ifdef HAVE_GETADDRINFO_A
-void (* rb_socket_before_fork_func)() = NULL;
-#endif
/* execv and execl are async-signal-safe since SUSv4 (POSIX.1-2008, XPG7) */
#if defined(__sun) && !defined(_XPG7) /* Solaris 10, 9, ... */
@@ -1624,13 +1621,6 @@ after_exec(void)
static void
before_fork_ruby(void)
{
-#ifdef HAVE_GETADDRINFO_A
- if (rb_socket_before_fork_func) {
- /* A mitigation for [Bug #17220]. See ext/socket/raddrinfo.c */
- rb_socket_before_fork_func();
- }
-#endif
-
before_exec();
}