* gc.c (rb_newobj): prohibit call of rb_newobj() during gc when

USE_VALUE_CACHE is not defined (normal case).



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17730 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
usa 2008-06-30 05:42:34 +00:00
parent 244e32db0d
commit eedb3dc3a3
2 changed files with 7 additions and 0 deletions

View File

@ -1,3 +1,8 @@
Mon Jun 30 14:41:36 2008 NAKAMURA Usaku <usa@ruby-lang.org>
* gc.c (rb_newobj): prohibit call of rb_newobj() during gc when
USE_VALUE_CACHE is not defined (normal case).
Mon Jun 30 10:28:33 2008 Yukihiro Matsumoto <matz@ruby-lang.org> Mon Jun 30 10:28:33 2008 Yukihiro Matsumoto <matz@ruby-lang.org>
* ext/syslog/syslog.c (syslog_write): syslog operations should be * ext/syslog/syslog.c (syslog_write): syslog operations should be

2
gc.c
View File

@ -732,6 +732,8 @@ rb_newobj(void)
return v; return v;
#else #else
rb_objspace_t *objspace = &rb_objspace; rb_objspace_t *objspace = &rb_objspace;
if (during_gc)
rb_bug("object allocation during garbage collection phase");
return rb_newobj_from_heap(objspace); return rb_newobj_from_heap(objspace);
#endif #endif
} }