gnunet-svn
[Top][All Lists]
Advanced

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

[taler-merchant] branch master updated: bug fix


From: gnunet
Subject: [taler-merchant] branch master updated: bug fix
Date: Thu, 12 Dec 2024 16:48:58 +0100

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

bohdan-potuzhnyi pushed a commit to branch master
in repository merchant.

The following commit(s) were added to refs/heads/master by this push:
     new db695516 bug fix
db695516 is described below

commit db6955167ab5b77f5a0c774c54a514069b6ccced
Author: bohdan-potuzhnyi <bohdan.potuzhnyi@gmail.com>
AuthorDate: Thu Dec 12 16:48:48 2024 +0100

    bug fix
---
 src/backend/taler-merchant-httpd.c                    | 1 +
 src/backend/taler-merchant-httpd_post-orders-ID-pay.c | 2 ++
 2 files changed, 3 insertions(+)

diff --git a/src/backend/taler-merchant-httpd.c 
b/src/backend/taler-merchant-httpd.c
index b320b5f8..2a4bcf25 100644
--- a/src/backend/taler-merchant-httpd.c
+++ b/src/backend/taler-merchant-httpd.c
@@ -505,6 +505,7 @@ handle_mhd_completion_callback (void *cls,
     json_decref (hc->request_body);
   if (NULL != hc->instance)
     TMH_instance_decref (hc->instance);
+  TMH_db->preflight(TMH_db->cls);
   GNUNET_free (hc->full_url);
   GNUNET_free (hc);
   *con_cls = NULL;
diff --git a/src/backend/taler-merchant-httpd_post-orders-ID-pay.c 
b/src/backend/taler-merchant-httpd_post-orders-ID-pay.c
index 5dece35d..4a5c7d3f 100644
--- a/src/backend/taler-merchant-httpd_post-orders-ID-pay.c
+++ b/src/backend/taler-merchant-httpd_post-orders-ID-pay.c
@@ -2240,6 +2240,7 @@ phase_execute_pay_transaction (struct PayContext *pc)
     else if (GNUNET_DB_STATUS_SUCCESS_NO_RESULTS == qs)
     {
       /* UNIQUE constraint violation, meaning this token was already used. */
+      TMH_db->rollback(TMH_db->cls);
       pay_end (pc,
                TALER_MHD_reply_with_error (pc->connection,
                                            MHD_HTTP_CONFLICT,
@@ -2274,6 +2275,7 @@ phase_execute_pay_transaction (struct PayContext *pc)
     }
     if (pc->deposit_currency_mismatch)
     {
+      TMH_db->rollback(TMH_db->cls);
       GNUNET_break_op (0);
       pay_end (pc,
                TALER_MHD_reply_with_error (pc->connection,

-- 
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]