Loading crypto/bn/bn_gcd.c +4 −8 Original line number Original line Diff line number Diff line Loading @@ -277,8 +277,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, if (!BN_uadd(Y, Y, X)) if (!BN_uadd(Y, Y, X)) goto err; goto err; /* /* * as above, BN_mod_add_quick(Y, Y, X, n) would slow things * as above, BN_mod_add_quick(Y, Y, X, n) would slow things down * down */ */ if (!BN_usub(A, A, B)) if (!BN_usub(A, A, B)) goto err; goto err; Loading Loading @@ -348,8 +347,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, * (**) sign*Y*a == D*B + M (mod |n|). * (**) sign*Y*a == D*B + M (mod |n|). */ */ tmp = A; /* keep the BIGNUM object, the value does not tmp = A; /* keep the BIGNUM object, the value does not matter */ * matter */ /* (A, B) := (B, A mod B) ... */ /* (A, B) := (B, A mod B) ... */ A = B; A = B; Loading Loading @@ -377,8 +375,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, */ */ /* /* * most of the time D is very small, so we can optimize tmp := * most of the time D is very small, so we can optimize tmp := D*X+Y * D*X+Y */ */ if (BN_is_one(D)) { if (BN_is_one(D)) { if (!BN_add(tmp, X, Y)) if (!BN_add(tmp, X, Y)) Loading @@ -403,8 +400,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, goto err; goto err; } } M = Y; /* keep the BIGNUM object, the value does not M = Y; /* keep the BIGNUM object, the value does not matter */ * matter */ Y = X; Y = X; X = tmp; X = tmp; sign = -sign; sign = -sign; Loading Loading
crypto/bn/bn_gcd.c +4 −8 Original line number Original line Diff line number Diff line Loading @@ -277,8 +277,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, if (!BN_uadd(Y, Y, X)) if (!BN_uadd(Y, Y, X)) goto err; goto err; /* /* * as above, BN_mod_add_quick(Y, Y, X, n) would slow things * as above, BN_mod_add_quick(Y, Y, X, n) would slow things down * down */ */ if (!BN_usub(A, A, B)) if (!BN_usub(A, A, B)) goto err; goto err; Loading Loading @@ -348,8 +347,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, * (**) sign*Y*a == D*B + M (mod |n|). * (**) sign*Y*a == D*B + M (mod |n|). */ */ tmp = A; /* keep the BIGNUM object, the value does not tmp = A; /* keep the BIGNUM object, the value does not matter */ * matter */ /* (A, B) := (B, A mod B) ... */ /* (A, B) := (B, A mod B) ... */ A = B; A = B; Loading Loading @@ -377,8 +375,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, */ */ /* /* * most of the time D is very small, so we can optimize tmp := * most of the time D is very small, so we can optimize tmp := D*X+Y * D*X+Y */ */ if (BN_is_one(D)) { if (BN_is_one(D)) { if (!BN_add(tmp, X, Y)) if (!BN_add(tmp, X, Y)) Loading @@ -403,8 +400,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in, goto err; goto err; } } M = Y; /* keep the BIGNUM object, the value does not M = Y; /* keep the BIGNUM object, the value does not matter */ * matter */ Y = X; Y = X; X = tmp; X = tmp; sign = -sign; sign = -sign; Loading