tests: remove secp256k1_fe_verify from tests.c and modify secp256k1_fe_from_storage to call secp256k1_fe_verify

1. secp256k1_fe_verify is removed from tests since, it throws an error if VERIFY is not defined during compilation.
   (Ex: ./configure --enable-coverage)
2. `secp256k1_fe_from_storage` calls `secp256k1_fe_verify` in the VERIFY build to check for invalid field element.
This commit is contained in:
siv2r
2021-10-02 15:52:05 +05:30
parent 2a3a97c665
commit d43993724d
3 changed files with 2 additions and 4 deletions

View File

@@ -496,6 +496,7 @@ static SECP256K1_INLINE void secp256k1_fe_from_storage(secp256k1_fe *r, const se
#ifdef VERIFY
r->magnitude = 1;
r->normalized = 1;
secp256k1_fe_verify(r);
#endif
}