diff options
author | tb <> | 2023-03-27 10:21:23 +0000 |
---|---|---|
committer | tb <> | 2023-03-27 10:21:23 +0000 |
commit | da1a532fc7d061a1f8b375580c6d9d22ea78970b (patch) | |
tree | 78bb6d4286a0a95d7729bde003bd20eb6757d89a /src/lib/libcrypto/ecdsa | |
parent | 62d326cb4e50a66b7d20ac55a0808f880deb43d9 (diff) | |
download | openbsd-da1a532fc7d061a1f8b375580c6d9d22ea78970b.tar.gz openbsd-da1a532fc7d061a1f8b375580c6d9d22ea78970b.tar.bz2 openbsd-da1a532fc7d061a1f8b375580c6d9d22ea78970b.zip |
Convert BN_copy() with explicit comparison against NULL to bn_copy()
ok jsing
Diffstat (limited to 'src/lib/libcrypto/ecdsa')
-rw-r--r-- | src/lib/libcrypto/ecdsa/ecs_ossl.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/libcrypto/ecdsa/ecs_ossl.c b/src/lib/libcrypto/ecdsa/ecs_ossl.c index 271c8435f8..25bcb06e88 100644 --- a/src/lib/libcrypto/ecdsa/ecs_ossl.c +++ b/src/lib/libcrypto/ecdsa/ecs_ossl.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ecs_ossl.c,v 1.29 2023/03/07 09:27:10 jsing Exp $ */ | 1 | /* $OpenBSD: ecs_ossl.c,v 1.30 2023/03/27 10:21:23 tb Exp $ */ |
2 | /* | 2 | /* |
3 | * Written by Nils Larsch for the OpenSSL project | 3 | * Written by Nils Larsch for the OpenSSL project |
4 | */ | 4 | */ |
@@ -322,7 +322,7 @@ ecdsa_do_sign(const unsigned char *dgst, int dgst_len, | |||
322 | ckinv = kinv; | 322 | ckinv = kinv; |
323 | } else { | 323 | } else { |
324 | ckinv = in_kinv; | 324 | ckinv = in_kinv; |
325 | if (BN_copy(ret->r, in_r) == NULL) { | 325 | if (!bn_copy(ret->r, in_r)) { |
326 | ECDSAerror(ERR_R_MALLOC_FAILURE); | 326 | ECDSAerror(ERR_R_MALLOC_FAILURE); |
327 | goto err; | 327 | goto err; |
328 | } | 328 | } |