aboutsummaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2021-08-01 19:18:31 +0200
committerChristian Grothoff <christian@grothoff.org>2021-08-01 19:18:35 +0200
commit18541a284b57ed7f0c110f084649eb292e603e63 (patch)
treee00abc102486ad4164742ea3205cb04d8419a51f /src/lib
parentac96733695ecc0ebe8e582e3230f2a95c89712bc (diff)
-allow 0 for refund deadline
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/exchange_api_common.c5
-rw-r--r--src/lib/exchange_api_deposit.c5
2 files changed, 6 insertions, 4 deletions
diff --git a/src/lib/exchange_api_common.c b/src/lib/exchange_api_common.c
index a564a367c..da1400b9d 100644
--- a/src/lib/exchange_api_common.c
+++ b/src/lib/exchange_api_common.c
@@ -527,8 +527,9 @@ TALER_EXCHANGE_verify_coin_history (
&dr.h_denom_pub),
TALER_JSON_spec_absolute_time_nbo ("timestamp",
&dr.wallet_timestamp),
- TALER_JSON_spec_absolute_time_nbo ("refund_deadline",
- &dr.refund_deadline),
+ GNUNET_JSON_spec_mark_optional (
+ TALER_JSON_spec_absolute_time_nbo ("refund_deadline",
+ &dr.refund_deadline)),
TALER_JSON_spec_amount_any_nbo ("deposit_fee",
&dr.deposit_fee),
GNUNET_JSON_spec_fixed_auto ("merchant_pub",
diff --git a/src/lib/exchange_api_deposit.c b/src/lib/exchange_api_deposit.c
index f22ae0df7..86f5034aa 100644
--- a/src/lib/exchange_api_deposit.c
+++ b/src/lib/exchange_api_deposit.c
@@ -680,8 +680,9 @@ TALER_EXCHANGE_deposit (struct TALER_EXCHANGE_Handle *exchange,
timestamp),
GNUNET_JSON_pack_data_auto ("merchant_pub",
merchant_pub),
- GNUNET_JSON_pack_time_abs ("refund_deadline",
- refund_deadline),
+ GNUNET_JSON_pack_allow_null (
+ GNUNET_JSON_pack_time_abs ("refund_deadline",
+ refund_deadline)),
GNUNET_JSON_pack_time_abs ("wire_transfer_deadline",
wire_deadline),
GNUNET_JSON_pack_data_auto ("coin_sig",