summaryrefslogtreecommitdiff
path: root/package/dropbear/patches/patch-libtommath_bn_mp_montgomery_setup_c
blob: a821eb2f93a67aaaf5f4ac047e3ba31c2e6ee2fd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
fix from
http://lists.openembedded.org/pipermail/openembedded-core/2013-May/079000.html

--- dropbear-2014.63.orig/libtommath/bn_mp_montgomery_setup.c	2014-02-19 15:05:24.000000000 +0100
+++ dropbear-2014.63/libtommath/bn_mp_montgomery_setup.c	2014-03-01 12:34:21.000000000 +0100
@@ -48,7 +48,7 @@ mp_montgomery_setup (mp_int * n, mp_digi
 #endif
 
   /* rho = -1/m mod b */
-  *rho = (unsigned long)(((mp_word)1 << ((mp_word) DIGIT_BIT)) - x) & MP_MASK;
+  *rho = (mp_digit)(((mp_word)1 << ((mp_word) DIGIT_BIT)) - x) & MP_MASK;
 
   return MP_OKAY;
 }