summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristian Grothoff <grothoff@gnunet.org>2024-01-14 16:45:07 +0100
committerChristian Grothoff <grothoff@gnunet.org>2024-01-14 16:45:07 +0100
commitbda1691194a3413cb7576169d50ee83b13ac88e7 (patch)
treeff387cab54b99015cd6120ce47de056e07c7761c /src
parent7538ee9ab776460ad1509b875ca283fef2d65397 (diff)
downloadexchange-bda1691194a3413cb7576169d50ee83b13ac88e7.tar.gz
exchange-bda1691194a3413cb7576169d50ee83b13ac88e7.tar.bz2
exchange-bda1691194a3413cb7576169d50ee83b13ac88e7.zip
more logging
Diffstat (limited to 'src')
-rw-r--r--src/util/wallet_signatures.c31
1 files changed, 25 insertions, 6 deletions
diff --git a/src/util/wallet_signatures.c b/src/util/wallet_signatures.c
index ebdb7eab9..19d30c7eb 100644
--- a/src/util/wallet_signatures.c
+++ b/src/util/wallet_signatures.c
@@ -201,16 +201,35 @@ TALER_wallet_deposit_verify (
amount);
TALER_amount_hton (&dr.deposit_fee,
deposit_fee);
+ // FIXME: this logging leaks memory!
GNUNET_log (GNUNET_ERROR_TYPE_INFO,
- "Validating deposit with hash %s, wallet timestamp %llu and refund deadline %llu by %s\n",
- GNUNET_h2s (&h_contract_terms->hash),
+ "Validating deposit with hash %s, wallet timestamp %llu and refund deadline %llu by %s wdh %s over %s\n",
+ GNUNET_STRINGS_data_to_string_alloc (&h_contract_terms->hash,
+ sizeof (h_contract_terms->
+ hash)),
(unsigned long long) wallet_timestamp.abs_time.abs_value_us,
(unsigned long long) refund_deadline.abs_time.abs_value_us,
- TALER_B2S (merchant_pub));
+ GNUNET_STRINGS_data_to_string_alloc (merchant_pub,
+ sizeof (*merchant_pub)),
+ wallet_data_hash == NULL
+ ? "NULL"
+ : GNUNET_STRINGS_data_to_string_alloc (wallet_data_hash,
+ sizeof (*wallet_data_hash)),
+ TALER_amount2s (amount));
GNUNET_log (GNUNET_ERROR_TYPE_INFO,
- "Denomination is %s, wire target is %s\n",
- GNUNET_h2s (&h_denom_pub->hash),
- TALER_B2S (h_wire));
+ "Acom %s h_pol %s Denomination is %s, deposit fee %s, wire target is %s\n",
+ h_age_commitment == NULL
+ ? "NULL"
+ : GNUNET_STRINGS_data_to_string_alloc (h_age_commitment,
+ sizeof (*h_age_commitment)),
+ h_policy == NULL
+ ? "NULL"
+ : GNUNET_STRINGS_data_to_string_alloc (h_policy,
+ sizeof (*h_policy)),
+ GNUNET_STRINGS_data_to_string_alloc (&h_denom_pub->hash,
+ sizeof (h_denom_pub->hash)),
+ TALER_amount2s (deposit_fee),
+ GNUNET_STRINGS_data_to_string_alloc (h_wire, sizeof (*h_wire)));
if (GNUNET_OK !=
GNUNET_CRYPTO_eddsa_verify (TALER_SIGNATURE_WALLET_COIN_DEPOSIT,
&dr,