gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-exchange] branch master updated: lookup_rules_by_access_token: do


From: gnunet
Subject: [taler-exchange] branch master updated: lookup_rules_by_access_token: do not filter out expired outcomes
Date: Mon, 09 Dec 2024 19:46:29 +0100

This is an automated email from the git hooks/post-receive script.

dold pushed a commit to branch master
in repository exchange.

The following commit(s) were added to refs/heads/master by this push:
     new 9c882c3c0 lookup_rules_by_access_token: do not filter out expired 
outcomes
9c882c3c0 is described below

commit 9c882c3c06caf6bce1f248e68e496cb6283efdf8
Author: Florian Dold <florian@dold.me>
AuthorDate: Mon Dec 9 19:46:24 2024 +0100

    lookup_rules_by_access_token: do not filter out expired outcomes
    
    Otherwise, successor measures can't be applied, as only default rules would 
apply
---
 src/exchange/taler-exchange-httpd_refund.c       | 2 +-
 src/exchangedb/exchangedb_aml.c                  | 3 +++
 src/exchangedb/pg_lookup_rules_by_access_token.c | 4 ----
 3 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/src/exchange/taler-exchange-httpd_refund.c 
b/src/exchange/taler-exchange-httpd_refund.c
index 4bb591a9c..b8bcf7c60 100644
--- a/src/exchange/taler-exchange-httpd_refund.c
+++ b/src/exchange/taler-exchange-httpd_refund.c
@@ -229,7 +229,7 @@ verify_and_execute_refund (struct MHD_Connection 
*connection,
                                             &refund->coin.coin_pub,
                                             &rctx.known_coin_id,
                                             &refund->coin.denom_pub_hash);
-    if (0 >= qs)
+    if (0 > qs)
     {
       MHD_RESULT res;
       char *dhs;
diff --git a/src/exchangedb/exchangedb_aml.c b/src/exchangedb/exchangedb_aml.c
index ffb86ee5f..765ec3861 100644
--- a/src/exchangedb/exchangedb_aml.c
+++ b/src/exchangedb/exchangedb_aml.c
@@ -651,6 +651,9 @@ fetch_latest_rules (void *cls)
   json_t *jnew_rules;
   enum GNUNET_GenericReturnValue res;
 
+  GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+              "Fetching latest rules.");
+
   ru->t = NULL;
   if (NULL != ru->eh)
   {
diff --git a/src/exchangedb/pg_lookup_rules_by_access_token.c 
b/src/exchangedb/pg_lookup_rules_by_access_token.c
index 74d58ec46..f6ed729ca 100644
--- a/src/exchangedb/pg_lookup_rules_by_access_token.c
+++ b/src/exchangedb/pg_lookup_rules_by_access_token.c
@@ -34,10 +34,8 @@ TEH_PG_lookup_rules_by_access_token (
   uint64_t *rowid)
 {
   struct PostgresClosure *pg = cls;
-  struct GNUNET_TIME_Absolute now;
   struct GNUNET_PQ_QueryParam params[] = {
     GNUNET_PQ_query_param_auto_from_type (h_payto),
-    GNUNET_PQ_query_param_absolute_time (&now),
     GNUNET_PQ_query_param_end
   };
   struct GNUNET_PQ_ResultSpec rs[] = {
@@ -60,12 +58,10 @@ TEH_PG_lookup_rules_by_access_token (
            ",outcome_serial_id AS row_id"
            " FROM legitimization_outcomes"
            " WHERE h_payto=$1"
-           "   AND expiration_time>$2"
            "   AND is_active"
            " ORDER BY expiration_time DESC,"
            "          outcome_serial_id DESC"
            " LIMIT 1;");
-  now = GNUNET_TIME_absolute_get ();
   return GNUNET_PQ_eval_prepared_singleton_select (
     pg->conn,
     "lookup_rules_by_access_token",

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]