summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-05-23 07:58:06 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-05-23 07:58:06 +0000
commit95170c704cdb84c318399e47c2867e3ce6034ba3 (patch)
tree957a345ff02dc6d4fcf13b6108585a4642982944
parent09c348239927dd6a09cfc747b746fa1087b0ba1c (diff)
* gc.c: do not dump the last record
* gc.c (gc_profile_dump_on): do not dump the last record, for some reason. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40898 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--gc.c1
2 files changed, 6 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index a98657b994..c8c93711a0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Thu May 23 16:58:01 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * gc.c (gc_profile_dump_on): do not dump the last record, for some
+ reason.
+
Wed May 22 16:50:18 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
* gc.c (gc_profile_dump_on): use size_t to get rid of overflow and
diff --git a/gc.c b/gc.c
index 81ac411403..7fa85ae0ce 100644
--- a/gc.c
+++ b/gc.c
@@ -5002,6 +5002,7 @@ gc_profile_dump_on(VALUE out, VALUE (*append)(VALUE, VALUE))
size_t i;
const gc_profile_record *record;
+ --count; /* do not dump the last record */
append(out, rb_sprintf("GC %"PRIuSIZE" invokes.\n", objspace->count));
append(out, rb_str_new_cstr("Index Invoke Time(sec) Use Size(byte) Total Size(byte) Total Object GC Time(ms)\n"));