summaryrefslogtreecommitdiff
path: root/ext/objspace
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-10-16 23:09:41 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-10-16 23:09:41 +0000
commit3304eb208af0b9062093cc9cd2042ba6d7e42418 (patch)
tree0ea87ec8b1121fb9a234b6cf5daac8672cea86f6 /ext/objspace
parenta1d96c9f47653d191e3bd1172598087e722b1560 (diff)
* ext/objspace/object_tracing.c (newobj_i): add workaround.
some bugs hits this check. * ext/objspace/object_tracing.c (object_allocations_reporter_i): cast as pointer. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43318 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/objspace')
-rw-r--r--ext/objspace/object_tracing.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/objspace/object_tracing.c b/ext/objspace/object_tracing.c
index 24d48d0..9de9724 100644
--- a/ext/objspace/object_tracing.c
+++ b/ext/objspace/object_tracing.c
@@ -99,7 +99,7 @@ newobj_i(VALUE tpval, void *data)
const char *class_path_cstr = RTEST(class_path) ? make_unique_str(arg->str_table, RSTRING_PTR(class_path), RSTRING_LEN(class_path)) : 0;
if (arg->keep_remains && st_lookup(arg->object_table, (st_data_t)obj, (st_data_t *)&info)) {
- if (info->living) rb_bug("newobj_i: reuse living object: %p", (void *)obj);
+ if (0 /* workaround */) if (info->living) rb_bug("newobj_i: reuse living object: %p", (void *)obj);
delete_unique_str(arg->str_table, info->path);
delete_unique_str(arg->str_table, info->class_path);
}
@@ -294,7 +294,7 @@ object_allocations_reporter_i(st_data_t key, st_data_t val, st_data_t ptr)
fprintf(out, "-- %p (%s F: %p, ", (void *)obj, info->living ? "live" : "dead", (void *)info->flags);
if (info->class_path) fprintf(out, "C: %s", info->class_path);
- else fprintf(out, "C: %p", info->klass);
+ else fprintf(out, "C: %p", (void *)info->klass);
fprintf(out, "@%s:%lu", info->path ? info->path : "", info->line);
if (!NIL_P(info->mid)) fprintf(out, " (%s)", rb_id2name(SYM2ID(info->mid)));
fprintf(out, ")\n");