From cc22ec85b9f1b6bf818fd8d456cc12e1460164c0 Mon Sep 17 00:00:00 2001 From: Tatsuhiko Kubo Date: Tue, 26 Aug 2014 09:05:12 +0900 Subject: Use mrb_malloc() instead of mrb_realloc(). --- src/gc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/gc.c b/src/gc.c index c33f1e662..30391a081 100644 --- a/src/gc.c +++ b/src/gc.c @@ -227,7 +227,7 @@ mrb_calloc(mrb_state *mrb, size_t nelem, size_t len) nelem <= SIZE_MAX / len) { size_t size; size = nelem * len; - p = mrb_realloc(mrb, 0, size); + p = mrb_malloc(mrb, size); memset(p, 0, size); } -- cgit v1.2.3