aboutsummaryrefslogtreecommitdiff
path: root/src/util/crypto.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2023-09-11 22:14:12 +0200
committerChristian Grothoff <christian@grothoff.org>2023-09-11 22:14:12 +0200
commit31b317de5945edda959fd653606e9d1bda260d14 (patch)
tree32be92a1b2d6a044d18b6e3e249274a1d6b91d8c /src/util/crypto.c
parent552cb25a3248b01be8de9485430e47dfe4d0a701 (diff)
check for no_age_commitment before using uninitialized age_commitment hash
Diffstat (limited to 'src/util/crypto.c')
-rw-r--r--src/util/crypto.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/util/crypto.c b/src/util/crypto.c
index 8699035c8..caa5a1223 100644
--- a/src/util/crypto.c
+++ b/src/util/crypto.c
@@ -85,7 +85,9 @@ TALER_test_coin_valid (const struct TALER_CoinPublicInfo *coin_public_info,
#endif
TALER_coin_pub_hash (&coin_public_info->coin_pub,
- &coin_public_info->h_age_commitment,
+ coin_public_info->no_age_commitment
+ ? NULL
+ : &coin_public_info->h_age_commitment,
&c_hash);
if (GNUNET_OK !=