diff options
Diffstat (limited to 'thread_pthread.c')
-rw-r--r-- | thread_pthread.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/thread_pthread.c b/thread_pthread.c index e064bf71be..c4cbd77ac5 100644 --- a/thread_pthread.c +++ b/thread_pthread.c @@ -1664,7 +1664,7 @@ rb_sigwait_sleep(rb_thread_t *th, int sigwait_fd, const struct timespec *ts) n = ppoll(&pfd, 1, to, 0); if (check_signals_nogvl(th, sigwait_fd)) return; - if (n || RUBY_VM_INTERRUPTED(th->ec)) + if (n || (th && RUBY_VM_INTERRUPTED(th->ec))) return; if (ts && timespec_update_expire(&diff, &end)) return; |