diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-10-17 15:15:24 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-10-17 15:15:24 (GMT) |
commit | e70b0460ea2b6bec55c0bcda34181a1b28b9a1e4 (patch) | |
tree | fb1fc4a61c8506841a33740b6b97799d88fe5cc0 /libtommath/bn_mp_init_size.c | |
parent | 6893ec40c9e47ef1cf2eb15fc4e656e44ff94fba (diff) | |
download | tcl-e70b0460ea2b6bec55c0bcda34181a1b28b9a1e4.zip tcl-e70b0460ea2b6bec55c0bcda34181a1b28b9a1e4.tar.gz tcl-e70b0460ea2b6bec55c0bcda34181a1b28b9a1e4.tar.bz2 |
Put back MP_CALLOC, since it's going to stay in libtommath
Diffstat (limited to 'libtommath/bn_mp_init_size.c')
-rw-r--r-- | libtommath/bn_mp_init_size.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/libtommath/bn_mp_init_size.c b/libtommath/bn_mp_init_size.c index 215de5a..d622687 100644 --- a/libtommath/bn_mp_init_size.c +++ b/libtommath/bn_mp_init_size.c @@ -9,8 +9,7 @@ mp_err mp_init_size(mp_int *a, int size) size = MP_MAX(MP_MIN_PREC, size); /* alloc mem */ - a->dp = (mp_digit *) MP_MALLOC((size_t)size * sizeof(mp_digit)); - MP_ZERO_DIGITS(a->dp, size); + a->dp = (mp_digit *) MP_CALLOC((size_t)size, sizeof(mp_digit)); if (a->dp == NULL) { return MP_MEM; } |