gnunet-svn
[Top][All Lists]
Advanced

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

[taler-merchant] 02/02: related to #6774: rollback AND suspend before st


From: gnunet
Subject: [taler-merchant] 02/02: related to #6774: rollback AND suspend before starting async activity
Date: Thu, 04 Mar 2021 10:56:22 +0100

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

grothoff pushed a commit to branch master
in repository merchant.

commit b21ae427f405ac4e54aba8aa5f6f2dcfa175a525
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Thu Mar 4 10:56:17 2021 +0100

    related to #6774: rollback AND suspend before starting async activity
---
 src/backend/taler-merchant-httpd_post-tips-ID-pickup.c | 18 ++++++++----------
 1 file changed, 8 insertions(+), 10 deletions(-)

diff --git a/src/backend/taler-merchant-httpd_post-tips-ID-pickup.c 
b/src/backend/taler-merchant-httpd_post-tips-ID-pickup.c
index 797d6f25..4809fee8 100644
--- a/src/backend/taler-merchant-httpd_post-tips-ID-pickup.c
+++ b/src/backend/taler-merchant-httpd_post-tips-ID-pickup.c
@@ -826,6 +826,13 @@ RETRY:
           if (! rollback)
           {
             TMH_db->rollback (TMH_db->cls);
+            MHD_suspend_connection (connection);
+            GNUNET_CONTAINER_DLL_insert (pc_head,
+                                         pc_tail,
+                                         pc);
+            pc->tt = GNUNET_SCHEDULER_add_delayed (EXCHANGE_TIMEOUT,
+                                                   &do_timeout,
+                                                   pc);
             rollback = true;
           }
           try_withdraw (pc,
@@ -835,17 +842,8 @@ RETRY:
           qs = GNUNET_DB_STATUS_SUCCESS_NO_RESULTS;
         }
       }
-      if (GNUNET_DB_STATUS_SUCCESS_NO_RESULTS == qs)
-      {
-        MHD_suspend_connection (connection);
-        GNUNET_CONTAINER_DLL_insert (pc_head,
-                                     pc_tail,
-                                     pc);
-        pc->tt = GNUNET_SCHEDULER_add_delayed (EXCHANGE_TIMEOUT,
-                                               &do_timeout,
-                                               pc);
+      if (rollback)
         return MHD_YES;
-      }
     }
     if (GNUNET_DB_STATUS_SUCCESS_NO_RESULTS != qs)
     {

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