[前][次][番号順一覧][スレッド一覧]

ruby-changes:49602

From: mame <ko1@a...>
Date: Tue, 9 Jan 2018 16:33:43 +0900 (JST)
Subject: [ruby-changes:49602] mame:r61717 (trunk): Fix the position of VM_ASSERT for "pthread_create failed for time"

mame	2018-01-09 16:33:38 +0900 (Tue, 09 Jan 2018)

  New Revision: 61717

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=61717

  Log:
    Fix the position of VM_ASSERT for "pthread_create failed for time"
    
    Fix r61706.  Thank you, Eric Wong. [ruby-core:84756]

  Modified files:
    trunk/thread_pthread.c
Index: thread_pthread.c
===================================================================
--- thread_pthread.c	(revision 61716)
+++ thread_pthread.c	(revision 61717)
@@ -1604,7 +1604,6 @@ rb_thread_create_timer_thread(void) https://github.com/ruby/ruby/blob/trunk/thread_pthread.c#L1604
 	if (err != 0) {
 	    rb_warn("pthread_attr_init failed for timer: %s, scheduling broken",
 		    strerror(err));
-	    VM_ASSERT(err == 0);
 	    return;
         }
 # ifdef PTHREAD_STACK_MIN
@@ -1673,6 +1672,7 @@ rb_thread_create_timer_thread(void) https://github.com/ruby/ruby/blob/trunk/thread_pthread.c#L1672
 	    else {
 		rb_warn("timer thread stack size: system default");
 	    }
+	    VM_ASSERT(err == 0);
 #if USE_SLEEPY_TIMER_THREAD
 	    CLOSE_INVALIDATE(normal[0]);
 	    CLOSE_INVALIDATE(normal[1]);

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]