You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, when I try to install bplib on Ubuntu 22.04, I get this error:
bplib/src/bp_fp2.c: In function ‘FP2_zero’:
bplib/src/bp_fp2.c:111:9: error: invalid use of void expression
111 | if (!BN_zero(a->f[0]) || !BN_zero(a->f[1]))
| ^
bplib/src/bp_fp2.c:111:30: error: invalid use of void expression
111 | if (!BN_zero(a->f[0]) || !BN_zero(a->f[1]))
| ^
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
[end of output]
I searched for this problem online and it seems that OpenSSL changed the behavior of BN_zero which no longer returns a success integer. They essentially changed BN_zero to do what BN_zero_ex used to do.
For an ultra quick fix I changed the following and it seems to work:
index 6d7d1c7..062dd32 100644
--- a/bplib/src/bp_fp2.c+++ b/bplib/src/bp_fp2.c@@ -108,8 +108,9 @@ void FP2_clear_free(FP2 *a)
int FP2_zero(FP2 *a)
{
- if (!BN_zero(a->f[0]) || !BN_zero(a->f[1]))- return 0;+ BN_zero(a->f[0]);+ BN_zero(a->f[1]);+
return 1;
}
The text was updated successfully, but these errors were encountered:
caro3801
added a commit
to caro3801/bplib
that referenced
this issue
Dec 15, 2022
Hi, when I try to install bplib on Ubuntu 22.04, I get this error:
I searched for this problem online and it seems that OpenSSL changed the behavior of
BN_zero
which no longer returns a success integer. They essentially changedBN_zero
to do whatBN_zero_ex
used to do.For an ultra quick fix I changed the following and it seems to work:
The text was updated successfully, but these errors were encountered: