From: Eric Wong Date: 2018-06-01T22:03:52+00:00 Subject: [ruby-core:87346] Re: [Ruby trunk Bug#14807] 2.6.0-preview2 segfaults on OpenBSD due to missing pthread_condattr_init call Thanks, r63548 Btw, is PTHREAD_COND_INITIALIZER supported on OpenBSD? Something like this: ``` --- a/thread_pthread.c +++ b/thread_pthread.c @@ -55,7 +55,7 @@ static struct { #if defined(HAVE_PTHREAD_CONDATTR_SETCLOCK) && \ defined(CLOCK_REALTIME) && defined(CLOCK_MONOTONIC) && \ defined(HAVE_CLOCK_GETTIME) -static pthread_condattr_t condattr_mono; +static pthread_condattr_t condattr_mono = PTHREAD_COND_INITIALIZER; static pthread_condattr_t *condattr_monotonic = &condattr_mono; #else static const void *const condattr_monotonic = NULL; ``` ...And reverting your patch. Should save a few instructions at startup since it avoids linkage and function call at startup. Unsubscribe: