gnunet-svn
[Top][All Lists]
Advanced

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

[taler-exchange] branch master updated (eb32dd62 -> 89a4f5bb)


From: gnunet
Subject: [taler-exchange] branch master updated (eb32dd62 -> 89a4f5bb)
Date: Sun, 29 Mar 2020 01:58:46 +0100

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

grothoff pushed a change to branch master
in repository exchange.

    from eb32dd62 fix leaks and bad RC logic wrt json reference copying
     new 0f5f27e8 fix minor leak from getopt
     new 937065ae fix leak of old keystate if loading of new keystate failed
     new 89a4f5bb fix indentation

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 src/exchange/taler-exchange-httpd.c                |  2 ++
 src/exchange/taler-exchange-httpd_keystate.c       |  9 +++++++-
 .../test_exchange_api_keys_cherry_picking.c        | 26 +++++++++-------------
 3 files changed, 21 insertions(+), 16 deletions(-)

diff --git a/src/exchange/taler-exchange-httpd.c 
b/src/exchange/taler-exchange-httpd.c
index f1777cf7..f5acd1cd 100644
--- a/src/exchange/taler-exchange-httpd.c
+++ b/src/exchange/taler-exchange-httpd.c
@@ -1241,6 +1241,8 @@ main (int argc,
                  GNUNET_log_setup ("taler-exchange-httpd",
                                    (NULL == loglev) ? "INFO" : loglev,
                                    logfile));
+  GNUNET_free_non_null (loglev);
+  GNUNET_free_non_null (logfile);
   if (NULL == cfgfile)
     cfgfile = GNUNET_strdup (GNUNET_OS_project_data_get ()->user_config_file);
   TEH_cfg = GNUNET_CONFIGURATION_create ();
diff --git a/src/exchange/taler-exchange-httpd_keystate.c 
b/src/exchange/taler-exchange-httpd_keystate.c
index 4117c13a..3e856633 100644
--- a/src/exchange/taler-exchange-httpd_keystate.c
+++ b/src/exchange/taler-exchange-httpd_keystate.c
@@ -986,6 +986,11 @@ reload_keys_sign_iter (
         now.abs_value_us) )
   {
     /* We use the most recent one, if it is valid now (not just in the near 
future) */
+    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+                "Found signing key valid until `%s'\n",
+                GNUNET_STRINGS_absolute_time_to_string (
+                  GNUNET_TIME_absolute_ntoh (
+                    key_state->current_sign_key_issue.issue.end)));
     key_state->current_sign_key_issue = *ski;
   }
   if (0 !=
@@ -1965,10 +1970,12 @@ TEH_KS_acquire_ (struct GNUNET_TIME_Absolute now,
   }
   if (NULL == internal_key_state)
   {
-    /* We tried and failed (again) to setup #internal_key_state */
+    /* We tried and failed to setup #internal_key_state */
     GNUNET_assert (0 == pthread_mutex_unlock (&internal_key_state_mutex));
     GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
                 "Failed to initialize key state\n");
+    if (NULL != os)
+      ks_free (os);
     return NULL;
   }
   key_state = internal_key_state;
diff --git a/src/testing/test_exchange_api_keys_cherry_picking.c 
b/src/testing/test_exchange_api_keys_cherry_picking.c
index 69d7e80c..ed11bd5e 100644
--- a/src/testing/test_exchange_api_keys_cherry_picking.c
+++ b/src/testing/test_exchange_api_keys_cherry_picking.c
@@ -163,19 +163,18 @@ run (void *cls,
      * current lookahead_sign == 60 seconds and the key's withdraw
      * duration is 80 seconds.
      *///
-    TALER_TESTING_cmd_exec_keyup_with_now
-      ("keyup-1",
-      CONFIG_FILE,
-      TTH_parse_time (JAN2030)),
+    TALER_TESTING_cmd_exec_keyup_with_now ("keyup-1",
+                                           CONFIG_FILE,
+                                           TTH_parse_time (JAN2030)),
     /**
-    * Should return 1 new key, + the original one.  NOTE: the
-    * original DK will never be 'cancelled' as for the current
-    * libtalerexchange logic, so it must always be counted.
-    */TALER_TESTING_cmd_check_keys_with_now
-      ("check-keys-2",
-      2,  /* generation */
-      2,
-      TTH_parse_time (JAN2030)),
+     * Should return 1 new key, + the original one.  NOTE: the
+     * original DK will never be 'cancelled' as for the current
+     * libtalerexchange logic, so it must always be counted.
+     *///
+    TALER_TESTING_cmd_check_keys_with_now ("check-keys-2",
+                                           2, /* generation */
+                                           2,
+                                           TTH_parse_time (JAN2030)),
     TALER_TESTING_cmd_exec_keyup_with_now
       ("keyup-3",
       CONFIG_FILE_EXTENDED_2,
@@ -184,7 +183,6 @@ run (void *cls,
        * overridden.  */
       ADDSECS (TTH_parse_time (JAN2030),
                10)),
-
     /**
      * Expected number of DK:
      *
@@ -205,11 +203,9 @@ run (void *cls,
       3 /* generation */,
       NDKS_RIGHT_BEFORE_SERIALIZATION,
       TTH_parse_time (JAN2030)),
-
     TALER_TESTING_cmd_end ()
   };
   struct TALER_TESTING_Command commands[] = {
-
     TALER_TESTING_cmd_batch ("ordinary-cherry-pick",
                              ordinary_cherry_pick),
     TALER_TESTING_cmd_batch ("keys-serialization",

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

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