diff options
author | Theo Buehler <tb@cvs.openbsd.org> | 2023-07-01 15:10:29 +0000 |
---|---|---|
committer | Theo Buehler <tb@cvs.openbsd.org> | 2023-07-01 15:10:29 +0000 |
commit | 2d589273371b0188fc5db7634c26eace0e8d8981 (patch) | |
tree | 97901b2a7c869127a56684e6a2e3948b42c4613f /lib | |
parent | 41b7cb5332d101078d6e7192b507f9bedd994d26 (diff) |
Reverse polarity to avoid an overlong line
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libcrypto/ecdh/ech_key.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/libcrypto/ecdh/ech_key.c b/lib/libcrypto/ecdh/ech_key.c index f7a73f795d7..8418073f8ac 100644 --- a/lib/libcrypto/ecdh/ech_key.c +++ b/lib/libcrypto/ecdh/ech_key.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ech_key.c,v 1.28 2023/07/01 15:09:54 tb Exp $ */ +/* $OpenBSD: ech_key.c,v 1.29 2023/07/01 15:10:28 tb Exp $ */ /* ==================================================================== * Copyright 2002 Sun Microsystems, Inc. ALL RIGHTS RESERVED. * @@ -185,10 +185,11 @@ ECDH_compute_key(void *out, size_t outlen, const EC_POINT *pub_key, EC_KEY *eckey, void *(*KDF)(const void *in, size_t inlen, void *out, size_t *outlen)) { - if (eckey->meth->compute_key != NULL) - return eckey->meth->compute_key(out, outlen, pub_key, eckey, KDF); - ECerror(EC_R_NOT_IMPLEMENTED); - return 0; + if (eckey->meth->compute_key == NULL) { + ECerror(EC_R_NOT_IMPLEMENTED); + return 0; + } + return eckey->meth->compute_key(out, outlen, pub_key, eckey, KDF); } int |