diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | gc.c | 6 | ||||
-rw-r--r-- | version.h | 2 |
3 files changed, 9 insertions, 3 deletions
@@ -1,3 +1,7 @@ +Mon Jun 9 03:21:20 2008 Tanaka Akira <akr@fsij.org> + + * gc.c (os_obj_of): assure to not free the scanning heap. + Mon Jun 9 03:20:12 2008 NAKAMURA Usaku <usa@ruby-lang.org> * io.c (rb_open_file, rb_io_s_sysopen): fmode should be unsigned int. @@ -1644,6 +1644,7 @@ os_obj_of(of) { int i; int n = 0; + volatile VALUE v; for (i = 0; i < heaps_used; i++) { RVALUE *p, *pend; @@ -1662,8 +1663,9 @@ os_obj_of(of) if (FL_TEST(p, FL_SINGLETON)) continue; default: if (!p->as.basic.klass) continue; - if (!of || rb_obj_is_kind_of((VALUE)p, of)) { - rb_yield((VALUE)p); + v = (VALUE)p; + if (!of || rb_obj_is_kind_of(v, of)) { + rb_yield(v); n++; } } @@ -2,7 +2,7 @@ #define RUBY_RELEASE_DATE "2008-06-09" #define RUBY_VERSION_CODE 187 #define RUBY_RELEASE_CODE 20080609 -#define RUBY_PATCHLEVEL 11 +#define RUBY_PATCHLEVEL 12 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 8 |