]> asedeno.scripts.mit.edu Git - PuTTY.git/commitdiff
Fix a casting bug with the length-independent sshbn code.
authorSimon Tatham <anakin@pobox.com>
Thu, 22 Jan 2004 18:37:48 +0000 (18:37 +0000)
committerSimon Tatham <anakin@pobox.com>
Thu, 22 Jan 2004 18:37:48 +0000 (18:37 +0000)
[originally from svn r3760]

sshbn.c

diff --git a/sshbn.c b/sshbn.c
index 8d4d703c3849af3cf4c6671c05b3281945b74699..7fe0309a03bf285a019d6f241442f26f4277e232 100644 (file)
--- a/sshbn.c
+++ b/sshbn.c
@@ -133,7 +133,7 @@ static void internal_add_shifted(BignumInt *number,
     int bshift = shift % BIGNUM_INT_BITS;
     BignumDblInt addend;
 
-    addend = n << bshift;
+    addend = (BignumDblInt)n << bshift;
 
     while (addend) {
        addend += number[word];