exchange

Base system with REST service to issue digital coins, run by the payment service provider
Log | Files | Refs | Submodules | README | LICENSE

commit 8c3e26a88043faf79f910862c8c2a3f1a1ecb912
parent f4bbc6db7e4b52662ee9fcb8abf860cff8ad45b9
Author: Christian Grothoff <christian@grothoff.org>
Date:   Wed,  9 Jul 2025 09:20:00 +0200

do not change value of timestamp in TALER_MHD_parse_request_timestamp if the option is not given

Diffstat:
Msrc/exchange/taler-exchange-httpd_aml-statistics-get.c | 6+++---
Msrc/mhd/mhd_parsing.c | 3---
2 files changed, 3 insertions(+), 6 deletions(-)

diff --git a/src/exchange/taler-exchange-httpd_aml-statistics-get.c b/src/exchange/taler-exchange-httpd_aml-statistics-get.c @@ -70,8 +70,8 @@ TEH_handler_aml_kyc_statistics_get ( const struct TALER_AmlOfficerPublicKeyP *officer_pub, const char *const args[]) { - struct GNUNET_TIME_Timestamp start_date; - struct GNUNET_TIME_Timestamp end_date; + struct GNUNET_TIME_Timestamp start_date = GNUNET_TIME_UNIT_ZERO_TS; + struct GNUNET_TIME_Timestamp end_date = GNUNET_TIME_UNIT_FOREVER_TS; const char *all_names = args[0]; json_t *stats; size_t max_names; @@ -92,7 +92,7 @@ TEH_handler_aml_kyc_statistics_get ( TALER_MHD_parse_request_timestamp (rc->connection, "end_date", &end_date); - if (GNUNET_TIME_absolute_is_zero (end_date.abs_time)) + if (GNUNET_TIME_absolute_is_never (end_date.abs_time)) end_date = GNUNET_TIME_absolute_to_timestamp ( GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_SECONDS)); GNUNET_log (GNUNET_ERROR_TYPE_INFO, diff --git a/src/mhd/mhd_parsing.c b/src/mhd/mhd_parsing.c @@ -229,10 +229,7 @@ TALER_MHD_parse_request_arg_timestamp ( MHD_GET_ARGUMENT_KIND, fname); if (NULL == s) - { - *ts = GNUNET_TIME_UNIT_ZERO_TS; return GNUNET_OK; - } if (GNUNET_OK != GNUNET_STRINGS_fancy_time_to_timestamp (s, ts))