From 779ce6b00ea711f1f6cffaebf2d8a837bb161a69 Mon Sep 17 00:00:00 2001 From: nobu Date: Sat, 10 May 2014 14:47:04 +0000 Subject: thread_pthread.c: compare with pthread_equal * thread_pthread.c (ubf_select): compare thread_id with pthread_equal() but not directly. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45906 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- thread_pthread.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'thread_pthread.c') diff --git a/thread_pthread.c b/thread_pthread.c index a00d7af1bf..ba7aa1ddca 100644 --- a/thread_pthread.c +++ b/thread_pthread.c @@ -1172,7 +1172,7 @@ ubf_select(void *ptr) * In the other hands, we shouldn't call rb_thread_wakeup_timer_thread() * if running on timer thread because it may make endless wakeups. */ - if (pthread_self() != timer_thread_id) + if (!pthread_equal(pthread_self(), timer_thread_id)) rb_thread_wakeup_timer_thread(); ubf_select_each(th); } -- cgit v1.2.3