Merge pull request #3683 from SparkiDev/sp_int_mont_red_1

SP math all: fix 1 word Montgomery Reduce
pull/3689/head
toddouska 2021-01-25 14:47:35 -08:00 committed by GitHub
commit f35f57c378
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -12065,7 +12065,7 @@ static int _sp_mont_red(sp_int* a, sp_int* m, sp_int_digit mp)
a->dp[1] = w; a->dp[1] = w;
w >>= SP_WORD_SIZE; w >>= SP_WORD_SIZE;
a->dp[2] = w; a->dp[2] = w;
a->used = m->used * 2; a->used = m->used * 2 + 1;
/* mp is SP_WORD_SIZE */ /* mp is SP_WORD_SIZE */
bits = SP_WORD_SIZE; bits = SP_WORD_SIZE;
} }