diff --git a/ChangeLog b/ChangeLog index 0312c62e6a6b3399bf63140aca572cf32d3f8827..4141e57dbb6e005fb4e91bddf857cd3a7f4ed83a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2018-07-12 Niels Möller + + * eccdata.c (output_curve): Replace mpz_init_set_ui by mpz_set_ui, + to fix memory leak. + 2018-07-08 Niels Möller * fat-x86_64.c (fat_init): Fix setup for nettle_sha1_compress. diff --git a/eccdata.c b/eccdata.c index a4723f1ea399977ff82fa82c2818ddbbf37c14ef..92e244bd1346d02b55d453389d8551ec43491982 100644 --- a/eccdata.c +++ b/eccdata.c @@ -1143,7 +1143,7 @@ output_curve (const struct ecc_curve *ecc, unsigned bits_per_limb) printf ("#else\n"); - mpz_init_set_ui (t, 1); + mpz_set_ui (t, 1); output_bignum ("ecc_unit", t, limb_size, bits_per_limb); printf ("static const mp_limb_t ecc_table[%lu] = {",