-/* $OpenBSD: ecp_smpl.c,v 1.33 2021/09/08 17:29:21 tb Exp $ */
+/* $OpenBSD: ecp_smpl.c,v 1.34 2022/01/20 11:02:44 inoguchi Exp $ */
/* Includes code written by Lenka Fibikova <fibikova@exp-math.uni-essen.de>
* for the OpenSSL project.
* Includes code written by Bodo Moeller for the OpenSSL project.
}
}
} else {
- if (!BN_mod_inverse_ct(Z_1, Z_, &group->field, ctx)) {
+ if (BN_mod_inverse_ct(Z_1, Z_, &group->field, ctx) == NULL) {
ECerror(ERR_R_BN_LIB);
goto err;
}
/* invert heap[1] */
if (!BN_is_zero(heap[1])) {
- if (!BN_mod_inverse_ct(heap[1], heap[1], &group->field, ctx)) {
+ if (BN_mod_inverse_ct(heap[1], heap[1], &group->field, ctx) == NULL) {
ECerror(ERR_R_BN_LIB);
goto err;
}