diff options
author | tb <> | 2024-12-07 13:32:07 +0000 |
---|---|---|
committer | tb <> | 2024-12-07 13:32:07 +0000 |
commit | 5d43f77047a902201b1a821f4991729fe913d64f (patch) | |
tree | edcd8dc215c6302f8a24397a17744c02362d418b /src | |
parent | 26b650816d89ff1a1ec83b06dc914cc231a56342 (diff) | |
download | openbsd-5d43f77047a902201b1a821f4991729fe913d64f.tar.gz openbsd-5d43f77047a902201b1a821f4991729fe913d64f.tar.bz2 openbsd-5d43f77047a902201b1a821f4991729fe913d64f.zip |
Move initialization of sign out of the middle of bits handling
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/libcrypto/ec/ec_mult.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libcrypto/ec/ec_mult.c b/src/lib/libcrypto/ec/ec_mult.c index dc3997c3b8..08c1196013 100644 --- a/src/lib/libcrypto/ec/ec_mult.c +++ b/src/lib/libcrypto/ec/ec_mult.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_mult.c,v 1.53 2024/12/06 15:49:37 tb Exp $ */ | 1 | /* $OpenBSD: ec_mult.c,v 1.54 2024/12/07 13:32:07 tb Exp $ */ |
2 | /* | 2 | /* |
3 | * Originally written by Bodo Moeller and Nils Larsch for the OpenSSL project. | 3 | * Originally written by Bodo Moeller and Nils Larsch for the OpenSSL project. |
4 | */ | 4 | */ |
@@ -115,10 +115,10 @@ ec_compute_wnaf(const BIGNUM *bn, signed char *digits, size_t num_digits) | |||
115 | goto err; | 115 | goto err; |
116 | } | 116 | } |
117 | 117 | ||
118 | wbits = ec_window_bits(bn); | ||
119 | |||
120 | sign = BN_is_negative(bn) ? -1 : 1; | 118 | sign = BN_is_negative(bn) ? -1 : 1; |
121 | 119 | ||
120 | wbits = ec_window_bits(bn); | ||
121 | |||
122 | bit = 1 << wbits; | 122 | bit = 1 << wbits; |
123 | next = bit << 1; | 123 | next = bit << 1; |
124 | 124 | ||