summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorTheo Buehler <tb@cvs.openbsd.org>2021-04-20 17:34:34 +0000
committerTheo Buehler <tb@cvs.openbsd.org>2021-04-20 17:34:34 +0000
commit5b8425faaab42a235aa95de318e6c3b0f787ab75 (patch)
tree2b8a90693f3a0b62f71d3d80d9364bcef1763637 /lib
parent49b39193135869a2fcadd7e30e80a2ec5ae031d1 (diff)
Compare pointer against NULL and fix a KNF issue.
ok jsing
Diffstat (limited to 'lib')
-rw-r--r--lib/libcrypto/ec/ec_oct.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libcrypto/ec/ec_oct.c b/lib/libcrypto/ec/ec_oct.c
index a3a826d0f12..45968219de9 100644
--- a/lib/libcrypto/ec/ec_oct.c
+++ b/lib/libcrypto/ec/ec_oct.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ec_oct.c,v 1.7 2021/04/20 17:32:57 tb Exp $ */
+/* $OpenBSD: ec_oct.c,v 1.8 2021/04/20 17:34:33 tb Exp $ */
/*
* Originally written by Bodo Moeller for the OpenSSL project.
*/
@@ -74,8 +74,8 @@ int
EC_POINT_set_compressed_coordinates(const EC_GROUP *group, EC_POINT *point,
const BIGNUM *x, int y_bit, BN_CTX *ctx)
{
- if (group->meth->point_set_compressed_coordinates == 0
- && !(group->meth->flags & EC_FLAGS_DEFAULT_OCT)) {
+ if (group->meth->point_set_compressed_coordinates == NULL &&
+ !(group->meth->flags & EC_FLAGS_DEFAULT_OCT)) {
ECerror(ERR_R_SHOULD_NOT_HAVE_BEEN_CALLED);
return 0;
}