From 4e0da4f0d82821ab6023d502f8c900ee381ca891 Mon Sep 17 00:00:00 2001 From: "Yukihiro \"Matz\" Matsumoto" Date: Fri, 26 Aug 2022 14:18:30 +0900 Subject: [PATCH] bigint.c (mpz_init_set): fully initialize mpz_t first. --- mrbgems/mruby-bigint/core/bigint.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mrbgems/mruby-bigint/core/bigint.c b/mrbgems/mruby-bigint/core/bigint.c index 11eda437c..84f6394ea 100644 --- a/mrbgems/mruby-bigint/core/bigint.c +++ b/mrbgems/mruby-bigint/core/bigint.c @@ -61,7 +61,7 @@ mpz_set(mrb_state *mrb, mpz_t *y, mpz_t *x) static void mpz_init_set(mrb_state *mrb, mpz_t *s, mpz_t *t) { - s->p = NULL; + mpz_init(mrb, s); mpz_set(mrb, s, t); }