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

ruby-changes:26699

From: glass <ko1@a...>
Date: Wed, 9 Jan 2013 22:14:21 +0900 (JST)
Subject: [ruby-changes:26699] glass:r38750 (trunk): * load.c (load_lock): if thread shield is destroyed and there is no

glass	2013-01-09 22:14:09 +0900 (Wed, 09 Jan 2013)

  New Revision: 38750

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=38750

  Log:
    * load.c (load_lock): if thread shield is destroyed and there is no
      waiting thread, insert new thread shield into load_table.
      [Bug #7530] [ruby-core:50645]

  Modified files:
    trunk/ChangeLog
    trunk/load.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 38749)
+++ ChangeLog	(revision 38750)
@@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Wed Jan  9 22:07:42 2013  Masaki Matsushita  <glass.saga@g...>
+
+	* load.c (load_lock): if thread shield is destroyed and there is no
+	  waiting thread, insert new thread shield into load_table.
+	  [Bug #7530] [ruby-core:50645]
+
 Wed Jan  9 21:43:32 2013  Masaki Matsushita  <glass.saga@g...>
 
 	* load.c (load_lock): revert r38744. it should acquire new thread
Index: load.c
===================================================================
--- load.c	(revision 38749)
+++ load.c	(revision 38750)
@@ -669,7 +669,7 @@ load_lock(const char *ftptr) https://github.com/ruby/ruby/blob/trunk/load.c#L669
     switch (rb_thread_shield_wait((VALUE)data)) {
       case Qfalse:
 	data = (st_data_t)ftptr;
-	st_delete(loading_tbl, &data, 0);
+	st_insert(loading_tbl, data, (st_data_t)rb_thread_shield_new());
 	return 0;
       case Qnil:
 	return 0;

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

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