summaryrefslogtreecommitdiff
path: root/src/util
diff options
context:
space:
mode:
authorÖzgür Kesim <oec-taler@kesim.org>2022-03-28 11:17:49 +0200
committerÖzgür Kesim <oec-taler@kesim.org>2022-03-28 11:17:49 +0200
commit488d217381b392ede199d55708ed73417a7828ed (patch)
treec2d72b2ef5ef3997ffbb1cbb5a8aa7e44f51f116 /src/util
parenta2386abadba4c211a00879f54ff030a86e491418 (diff)
downloadexchange-488d217381b392ede199d55708ed73417a7828ed.tar.gz
exchange-488d217381b392ede199d55708ed73417a7828ed.tar.bz2
exchange-488d217381b392ede199d55708ed73417a7828ed.zip
-fix leaks in test_crypto.c
Diffstat (limited to 'src/util')
-rw-r--r--src/util/test_crypto.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/util/test_crypto.c b/src/util/test_crypto.c
index 84c840093..c9f690b2b 100644
--- a/src/util/test_crypto.c
+++ b/src/util/test_crypto.c
@@ -129,12 +129,11 @@ test_planchets_rsa (uint8_t age)
if (0 < age)
{
+ struct TALER_AgeCommitmentProof acp;
struct TALER_AgeCommitmentHash ah = {0};
uint64_t salt = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK,
UINT64_MAX);
- struct TALER_AgeCommitmentProof acp;
-
GNUNET_assert (GNUNET_OK ==
TALER_age_restriction_commit (&age_mask,
age,
@@ -143,6 +142,7 @@ test_planchets_rsa (uint8_t age)
TALER_age_commitment_hash (&acp.commitment,
&ah);
ach = &ah;
+ TALER_age_commitment_proof_free (&acp);
}
GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_STRONG,
@@ -271,6 +271,7 @@ test_planchets_cs (uint8_t age)
TALER_age_commitment_hash (&acp.commitment,
&ah);
ach = &ah;
+ TALER_age_commitment_proof_free (&acp);
}
GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_STRONG,