diff --git a/load.c b/load.c index 81d943cbe0..463c890f91 100644 --- a/load.c +++ b/load.c @@ -258,7 +258,7 @@ loaded_features_index_clear_i(st_data_t key, st_data_t val, st_data_t arg) VALUE obj = (VALUE)val; if (!SPECIAL_CONST_P(obj)) { rb_ary_free(obj); - xfree((void *)obj); + ruby_sized_xfree((void *)obj, sizeof(struct RArray)); } return ST_DELETE; }