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

ruby-changes:11454

From: shyouhei <ko1@a...>
Date: Fri, 27 Mar 2009 19:25:30 +0900 (JST)
Subject: [ruby-changes:11454] Ruby:r23079 (ruby_1_8_7): merge revision(s) 22882,22961,22971:

shyouhei	2009-03-27 19:25:23 +0900 (Fri, 27 Mar 2009)

  New Revision: 23079

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

  Log:
    merge revision(s) 22882,22961,22971:
    * gc.c (run_final): calls free function.  [ruby-core:22578]
    * gc.c (rb_gc_call_finalizer_at_exit): leave Thread objects
      unfinalized.  [ruby-dev:38168]
    * gc.c (run_final): frees zombies only.  [ruby-dev:38171]

  Modified files:
    branches/ruby_1_8_7/ChangeLog
    branches/ruby_1_8_7/gc.c
    branches/ruby_1_8_7/version.h

Index: ruby_1_8_7/ChangeLog
===================================================================
--- ruby_1_8_7/ChangeLog	(revision 23078)
+++ ruby_1_8_7/ChangeLog	(revision 23079)
@@ -1,3 +1,16 @@
+Fri Mar 27 19:22:02 2009  Nobuyoshi Nakada  <nobu@r...>
+
+	* gc.c (run_final): frees zombies only.  [ruby-dev:38171]
+
+Fri Mar 27 19:22:02 2009  Nobuyoshi Nakada  <nobu@r...>
+
+	* gc.c (rb_gc_call_finalizer_at_exit): leave Thread objects
+	  unfinalized.  [ruby-dev:38168]
+
+Fri Mar 27 19:22:02 2009  Nobuyoshi Nakada  <nobu@r...>
+
+	* gc.c (run_final): calls free function.  [ruby-core:22578]
+
 Mon Mar 23 19:17:06 2009  Nobuyoshi Nakada  <nobu@r...>
 
 	* ext/thread/thread.c (rb_queue_pop, rb_queue_push): should not lock
Index: ruby_1_8_7/version.h
===================================================================
--- ruby_1_8_7/version.h	(revision 23078)
+++ ruby_1_8_7/version.h	(revision 23079)
@@ -1,15 +1,15 @@
 #define RUBY_VERSION "1.8.7"
-#define RUBY_RELEASE_DATE "2009-03-23"
+#define RUBY_RELEASE_DATE "2009-03-27"
 #define RUBY_VERSION_CODE 187
-#define RUBY_RELEASE_CODE 20090323
-#define RUBY_PATCHLEVEL 153
+#define RUBY_RELEASE_CODE 20090327
+#define RUBY_PATCHLEVEL 154
 
 #define RUBY_VERSION_MAJOR 1
 #define RUBY_VERSION_MINOR 8
 #define RUBY_VERSION_TEENY 7
 #define RUBY_RELEASE_YEAR 2009
 #define RUBY_RELEASE_MONTH 3
-#define RUBY_RELEASE_DAY 23
+#define RUBY_RELEASE_DAY 27
 
 #ifdef RUBY_EXTERN
 RUBY_EXTERN const char ruby_version[];
Index: ruby_1_8_7/gc.c
===================================================================
--- ruby_1_8_7/gc.c	(revision 23078)
+++ ruby_1_8_7/gc.c	(revision 23079)
@@ -1942,6 +1942,9 @@
 
     objid = rb_obj_id(obj);	/* make obj into id */
     rb_thread_critical = Qtrue;
+    if (BUILTIN_TYPE(obj) == T_DEFERRED && RDATA(obj)->dfree) {
+	(*RDATA(obj)->dfree)(DATA_PTR(obj));
+    }
     args[1] = 0;
     args[2] = (VALUE)ruby_safe_level;
     for (i=0; i<RARRAY(finalizers)->len; i++) {
@@ -2010,7 +2013,8 @@
 	p = heaps[i].slot; pend = p + heaps[i].limit;
 	while (p < pend) {
 	    if (BUILTIN_TYPE(p) == T_DATA &&
-		DATA_PTR(p) && RANY(p)->as.data.dfree) {
+		DATA_PTR(p) && RANY(p)->as.data.dfree &&
+		RANY(p)->as.basic.klass != rb_cThread) {
 		p->as.free.flags = 0;
 		if ((long)RANY(p)->as.data.dfree == -1) {
 		    RUBY_CRITICAL(free(DATA_PTR(p)));

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

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