diff options
Diffstat (limited to 'src/struct.c')
| -rw-r--r-- | src/struct.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/struct.c b/src/struct.c index e9266ad17..2e2e0c10f 100644 --- a/src/struct.c +++ b/src/struct.c @@ -450,7 +450,7 @@ mrb_struct_new(mrb_state *mrb, struct RClass *klass, ...) size = mrb_long2int(num_members(mrb, klass)); if (size > numberof(tmpargs)) { - tmpargs[0] = mrb_ary_tmp_new(mrb, size); + tmpargs[0] = mrb_ary_new_capa(mrb, size); mem = RARRAY_PTR(tmpargs[0]); } va_start(args, klass); |
