gnunet-svn
[Top][All Lists]
Advanced

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

[taler-exchange] 03/03: -code cleanup


From: gnunet
Subject: [taler-exchange] 03/03: -code cleanup
Date: Sat, 19 Mar 2022 08:35:20 +0100

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

grothoff pushed a commit to branch master
in repository exchange.

commit 52a8b8f888b84e9c076e3e2f26587cff079f6ea4
Author: Christian Grothoff <grothoff@gnunet.org>
AuthorDate: Sat Mar 19 08:34:58 2022 +0100

    -code cleanup
---
 src/lib/auditor_api_handle.c | 17 ++++++-----------
 1 file changed, 6 insertions(+), 11 deletions(-)

diff --git a/src/lib/auditor_api_handle.c b/src/lib/auditor_api_handle.c
index a1ffe6c3..a5478ef9 100644
--- a/src/lib/auditor_api_handle.c
+++ b/src/lib/auditor_api_handle.c
@@ -286,6 +286,8 @@ version_completed_cb (void *cls,
               "Received version from URL `%s' with status %ld.\n",
               vr->url,
               response_code);
+  free_version_request (vr);
+  auditor->vr = NULL;
   vc = TALER_AUDITOR_VC_PROTOCOL_ERROR;
   switch (response_code)
   {
@@ -293,8 +295,6 @@ version_completed_cb (void *cls,
   case MHD_HTTP_INTERNAL_SERVER_ERROR:
     /* NOTE: this design is debatable. We MAY want to throw this error at the
        client. We may then still additionally internally re-try. */
-    free_version_request (vr);
-    auditor->vr = NULL;
     GNUNET_assert (NULL == auditor->retry_task);
     auditor->retry_delay = EXCHANGE_LIB_BACKOFF (auditor->retry_delay);
     auditor->retry_task = GNUNET_SCHEDULER_add_delayed (auditor->retry_delay,
@@ -333,11 +333,9 @@ version_completed_cb (void *cls,
   if (MHD_HTTP_OK != response_code)
   {
     GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
-                "/version failed for auditor %p: %u!\n",
-                auditor,
+                "/version failed for auditor %s: %u!\n",
+                auditor->url,
                 (unsigned int) response_code);
-    auditor->vr = NULL;
-    free_version_request (vr);
     auditor->state = MHS_FAILED;
     /* notify application that we failed */
     auditor->version_cb (auditor->version_cb_cls,
@@ -346,14 +344,11 @@ version_completed_cb (void *cls,
                          vc);
     return;
   }
-
-  auditor->vr = NULL;
-  free_version_request (vr);
   TALER_LOG_DEBUG ("Switching auditor state to 'version'\n");
   auditor->state = MHS_VERSION;
   GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-              "Auditor %p is now READY!\n",
-              auditor);
+              "Auditor %s is now READY!\n",
+              auditor->url);
   /* notify application about the key information */
   auditor->version_cb (auditor->version_cb_cls,
                        &hr,

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