Implement various _clear() functions with secp256k1_memclear()

This commit is contained in:
Tim Ruffing
2019-06-08 11:29:49 +02:00
committed by Sebastian Falbesoner
parent 9bb368d146
commit 97c57f42ba
9 changed files with 10 additions and 55 deletions

View File

@@ -212,13 +212,6 @@ SECP256K1_INLINE static int secp256k1_fe_impl_is_odd(const secp256k1_fe *a) {
return a->n[0] & 1;
}
SECP256K1_INLINE static void secp256k1_fe_impl_clear(secp256k1_fe *a) {
int i;
for (i=0; i<5; i++) {
a->n[i] = 0;
}
}
static int secp256k1_fe_impl_cmp_var(const secp256k1_fe *a, const secp256k1_fe *b) {
int i;
for (i = 4; i >= 0; i--) {