diff options
author | Marco Bodrato <bodrato@mail.dm.unipi.it> | 2014-05-20 19:44:39 +0200 |
---|---|---|
committer | Marco Bodrato <bodrato@mail.dm.unipi.it> | 2014-05-20 19:44:39 +0200 |
commit | c223ef16d7fe706becb8c815688820a6a0fa66d6 (patch) | |
tree | 064c5d983ece8ee3b3ffa50541d3f8e580ce3ef7 /rand | |
parent | 7850a2847129193c8fe15ba0e7105d859fe6aea8 (diff) | |
download | gmp-c223ef16d7fe706becb8c815688820a6a0fa66d6.tar.gz |
+1 in the init2 argument before setbit. (Thanks Niels)
Diffstat (limited to 'rand')
-rw-r--r-- | rand/randmts.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/rand/randmts.c b/rand/randmts.c index 1db785514..7c1c262f5 100644 --- a/rand/randmts.c +++ b/rand/randmts.c @@ -1,6 +1,6 @@ /* Mersenne Twister pseudo-random number generator functions. -Copyright 2002, 2003, 2013 Free Software Foundation, Inc. +Copyright 2002, 2003, 2013, 2014 Free Software Foundation, Inc. This file is part of the GNU MP Library. @@ -117,7 +117,7 @@ randseed_mt (gmp_randstate_t rstate, mpz_srcptr seed) p = (gmp_rand_mt_struct *) RNG_STATE (rstate); - mpz_init2 (mod, 19937L); + mpz_init2 (mod, 19938L); mpz_init2 (seed1, 19937L); mpz_setbit (mod, 19937L); |