diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | gc.c | 3 | ||||
-rw-r--r-- | version.h | 6 |
3 files changed, 11 insertions, 4 deletions
@@ -1,3 +1,9 @@ +Mon Apr 8 00:10:59 2013 Narihiro Nakamura <authornari@gmail.com> + + * gc.c: Fix unlimited memory growth with large values of + RUBY_FREE_MIN. patched by tmm1(Aman Gupta). + [Bug #8095] [ruby-core:53405] + Sun Apr 7 22:27:12 2013 Narihiro Nakamura <authornari@gmail.com> * gc.c: Avoid unnecessary heap growth. patched by tmm1(Aman Gupta). @@ -1968,8 +1968,9 @@ before_gc_sweep(rb_objspace_t *objspace) objspace->heap.do_heap_free = (size_t)((heaps_used * HEAP_OBJ_LIMIT) * 0.65); objspace->heap.free_min = (size_t)((heaps_used * HEAP_OBJ_LIMIT) * 0.2); if (objspace->heap.free_min < initial_free_min) { - objspace->heap.do_heap_free = heaps_used * HEAP_OBJ_LIMIT; objspace->heap.free_min = initial_free_min; + if (objspace->heap.do_heap_free < initial_free_min) + objspace->heap.do_heap_free = initial_free_min; } objspace->heap.sweep_slots = heaps; objspace->heap.free_num = 0; @@ -1,10 +1,10 @@ #define RUBY_VERSION "2.0.0" -#define RUBY_RELEASE_DATE "2013-04-07" -#define RUBY_PATCHLEVEL 110 +#define RUBY_RELEASE_DATE "2013-04-08" +#define RUBY_PATCHLEVEL 111 #define RUBY_RELEASE_YEAR 2013 #define RUBY_RELEASE_MONTH 4 -#define RUBY_RELEASE_DAY 7 +#define RUBY_RELEASE_DAY 8 #include "ruby/version.h" |