summaryrefslogtreecommitdiffstats
path: root/libtommath/bn_mp_read_radix.c
diff options
context:
space:
mode:
authorKevin B Kenny <kennykb@acm.org>2005-12-27 17:59:37 (GMT)
committerKevin B Kenny <kennykb@acm.org>2005-12-27 17:59:37 (GMT)
commit32dabb168bc76e93bb522c8de30e3023df038a0f (patch)
treec5c780d07b7da7ee1542cef409ca020ecad97c63 /libtommath/bn_mp_read_radix.c
parent23d966feecf52e4d2f8ffb358c375bf4ecee8d8a (diff)
downloadtcl-32dabb168bc76e93bb522c8de30e3023df038a0f.zip
tcl-32dabb168bc76e93bb522c8de30e3023df038a0f.tar.gz
tcl-32dabb168bc76e93bb522c8de30e3023df038a0f.tar.bz2
Import of libtommath 0.37
Diffstat (limited to 'libtommath/bn_mp_read_radix.c')
-rw-r--r--libtommath/bn_mp_read_radix.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/libtommath/bn_mp_read_radix.c b/libtommath/bn_mp_read_radix.c
index ca2bde5..1aea788 100644
--- a/libtommath/bn_mp_read_radix.c
+++ b/libtommath/bn_mp_read_radix.c
@@ -21,6 +21,9 @@ int mp_read_radix (mp_int * a, const char *str, int radix)
int y, res, neg;
char ch;
+ /* zero the digit bignum */
+ mp_zero(a);
+
/* make sure the radix is ok */
if (radix < 2 || radix > 64) {
return MP_VAL;
@@ -78,5 +81,5 @@ int mp_read_radix (mp_int * a, const char *str, int radix)
#endif
/* $Source: /root/tcl/repos-to-convert/tcl/libtommath/bn_mp_read_radix.c,v $ */
-/* $Revision: 1.1.1.3 $ */
-/* $Date: 2005/09/26 16:31:56 $ */
+/* $Revision: 1.1.1.4 $ */
+/* $Date: 2005/12/27 17:59:38 $ */