diff options
author | Marco Bodrato <bodrato@mail.dm.unipi.it> | 2013-01-16 09:46:28 +0100 |
---|---|---|
committer | Marco Bodrato <bodrato@mail.dm.unipi.it> | 2013-01-16 09:46:28 +0100 |
commit | d09f9c6d9e3856c69df41300349521f6c9035f95 (patch) | |
tree | bf54a13bdc04b9560f60d4c1a2d2f3f1a3f3752f | |
parent | f50927e766eb2fe62a960429cd73de1dfd954f23 (diff) | |
download | gmp-d09f9c6d9e3856c69df41300349521f6c9035f95.tar.gz |
mini-gmp/mini-gmp.c (mpz_cmp_d): Correct multiword comparisons
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | mini-gmp/mini-gmp.c | 2 |
2 files changed, 5 insertions, 1 deletions
@@ -1,3 +1,7 @@ +2013-01-16 Marco Bodrato <bodrato@mail.dm.unipi.it> + + * mini-gmp/mini-gmp.c (mpz_cmp_d): Correct multiword comparison. + 2013-01-15 Niels Möller <nisse@lysator.liu.se> * mini-gmp/tests/t-str.c (main): Use x->_mp_d rather than x[0]._mp_d. diff --git a/mini-gmp/mini-gmp.c b/mini-gmp/mini-gmp.c index 84f3312cf..f55fb8785 100644 --- a/mini-gmp/mini-gmp.c +++ b/mini-gmp/mini-gmp.c @@ -1585,7 +1585,7 @@ mpz_cmp_d (const mpz_t x, double d) if (d >= B) return -sign; - for (i = xn; i-- > 0; i++) + for (i = xn; i-- > 0; i) { mp_limb_t f, xl; |