diff options
Diffstat (limited to 'thread_pthread.c')
-rw-r--r-- | thread_pthread.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/thread_pthread.c b/thread_pthread.c index 332e97be21..f9fa97bf8c 100644 --- a/thread_pthread.c +++ b/thread_pthread.c @@ -1274,7 +1274,8 @@ rb_thread_create_timer_thread(void) #ifdef HAVE_PTHREAD_ATTR_INIT pthread_attr_t attr; - if (pthread_attr_init(&attr)) { + err = pthread_attr_init(&attr); + if (err != 0) { fprintf(stderr, "[FATAL] Failed to initialize pthread attr(errno: %d)\n", err); exit(EXIT_FAILURE); } |