exchange

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

commit 0b1d892f601cbdfcaf1bf326d2a9921fad6ab0a2
parent 5c485d9eb1294d74f56fafc58e547ea32115afb2
Author: Christian Grothoff <christian@grothoff.org>
Date:   Mon, 29 Jun 2026 19:04:14 +0200

fix loop termination bug

Diffstat:
Msrc/exchangedb/update_rules.c | 10++++++++++
Msrc/testing/testing_api_loop.c | 10++++++----
2 files changed, 16 insertions(+), 4 deletions(-)

diff --git a/src/exchangedb/update_rules.c b/src/exchangedb/update_rules.c @@ -388,6 +388,16 @@ run_measure (struct TALER_EXCHANGEDB_RuleUpdater *ru, GNUNET_TIME_relative_multiply (ru->pg->max_aml_program_runtime, 2), &xlock); + if (qs <= 0) + { + GNUNET_break (GNUNET_DB_STATUS_SOFT_ERROR == qs); + fail_update (ru, + GNUNET_DB_STATUS_SOFT_ERROR == qs + ? TALER_EC_GENERIC_DB_SOFT_FAILURE + : TALER_EC_GENERIC_DB_STORE_FAILED, + "set_aml_lock"); + return; + } if (GNUNET_TIME_absolute_is_future (xlock)) { struct TALER_EXCHANGEDB_KycCompletedEventP eh = { diff --git a/src/testing/testing_api_loop.c b/src/testing/testing_api_loop.c @@ -796,7 +796,7 @@ seek_batch (struct TALER_TESTING_Interpreter *is, &batch)); match = NULL; for (new_ip = 0; - NULL != (icmd = &batch[new_ip]); + NULL != (icmd = &batch[new_ip])->label; new_ip++) { if (current == target) @@ -808,9 +808,11 @@ seek_batch (struct TALER_TESTING_Interpreter *is, } if (TALER_TESTING_cmd_is_batch (icmd)) { - int ret = seek_batch (is, - icmd, - target); + enum GNUNET_GenericReturnValue ret; + + ret = seek_batch (is, + icmd, + target); if (GNUNET_SYSERR == ret) return GNUNET_SYSERR; /* failure! */ if (GNUNET_OK == ret)