Skip to content

Commit

Permalink
Fix test after rb_intern has been suppressed
Browse files Browse the repository at this point in the history
  • Loading branch information
peterzhu2118 committed Nov 9, 2023
1 parent d7e41d1 commit 4dfb3ba
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions test/ruby_memcheck/ext/ruby_memcheck_c_test_one.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,9 @@ static VALUE c_test_one_uninitialized_value(VALUE _)

static VALUE c_test_one_call_into_ruby_mem_leak(VALUE obj)
{
char str[20];
for (int i = 0; i < 10000; i++) {
sprintf(str, "foobar%d", i);
rb_intern(str);
VALUE obj = rb_eval_string("Array.new(10000)");
rb_gc_register_mark_object(obj);
}
return Qnil;
}
Expand Down

0 comments on commit 4dfb3ba

Please sign in to comment.