diff options
author | marha <marha@users.sourceforge.net> | 2012-05-03 10:39:51 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-05-03 10:39:51 +0200 |
commit | 29ab820c34534f18a74ddb0c39cd2ed3692c7840 (patch) | |
tree | aa663b0d5b9998be6770429762c003d9ce9afc5e /tools/plink | |
parent | e219639a5f9f7d5f0fa40b9691c9dd596115d8ac (diff) | |
download | vcxsrv-29ab820c34534f18a74ddb0c39cd2ed3692c7840.tar.gz vcxsrv-29ab820c34534f18a74ddb0c39cd2ed3692c7840.tar.bz2 vcxsrv-29ab820c34534f18a74ddb0c39cd2ed3692c7840.zip |
Solved some type cast problems when running in debug
Diffstat (limited to 'tools/plink')
-rw-r--r-- | tools/plink/sshbn.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/plink/sshbn.c b/tools/plink/sshbn.c index 2e101942b..bf149cd77 100644 --- a/tools/plink/sshbn.c +++ b/tools/plink/sshbn.c @@ -172,7 +172,7 @@ static BignumInt internal_add(const BignumInt *a, const BignumInt *b, for (i = len-1; i >= 0; i--) {
carry += (BignumDblInt)a[i] + b[i];
- c[i] = (BignumInt)carry;
+ c[i] = (BignumInt)(carry&BIGNUM_INT_MASK);
carry >>= BIGNUM_INT_BITS;
}
@@ -192,7 +192,7 @@ static void internal_sub(const BignumInt *a, const BignumInt *b, for (i = len-1; i >= 0; i--) {
carry += (BignumDblInt)a[i] + (b[i] ^ BIGNUM_INT_MASK);
- c[i] = (BignumInt)carry;
+ c[i] = (BignumInt)(carry&BIGNUM_INT_MASK);
carry >>= BIGNUM_INT_BITS;
}
}
@@ -520,7 +520,7 @@ static void internal_mul_low(const BignumInt *a, const BignumInt *b, carry = 0;
for (cp = cps, bp = b + len; bp--, cp-- > c ;) {
t = (MUL_WORD(*ap, *bp) + carry) + *cp;
- *cp = (BignumInt) t;
+ *cp = (BignumInt) (t&BIGNUM_INT_MASK);
carry = (BignumInt)(t >> BIGNUM_INT_BITS);
}
}
@@ -1390,7 +1390,7 @@ Bignum bigmuladd(Bignum a, Bignum b, Bignum addend) for (i = 1; i <= rlen; i++) {
carry += (i <= (int)ret[0] ? ret[i] : 0);
carry += (i <= (int)addend[0] ? addend[i] : 0);
- ret[i] = (BignumInt) carry & BIGNUM_INT_MASK;
+ ret[i] = (BignumInt) (carry & BIGNUM_INT_MASK);
carry >>= BIGNUM_INT_BITS;
if (ret[i] != 0 && i > maxspot)
maxspot = i;
|