gnunet-svn
[Top][All Lists]
Advanced

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

[taler-exchange] branch master updated: -fix leaks


From: gnunet
Subject: [taler-exchange] branch master updated: -fix leaks
Date: Sun, 29 Oct 2023 20:27:26 +0100

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

grothoff pushed a commit to branch master
in repository exchange.

The following commit(s) were added to refs/heads/master by this push:
     new 9d71f037 -fix leaks
9d71f037 is described below

commit 9d71f037c015246ff5b2a804771cff9d84eb95dd
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Sun Oct 29 20:27:23 2023 +0100

    -fix leaks
---
 src/exchangedb/pg_do_age_withdraw.c       | 11 +++++++----
 src/exchangedb/pg_do_deposit.c            | 11 +++++++----
 src/exchangedb/pg_get_link_data.c         |  1 +
 src/exchangedb/pg_get_refresh_reveal.c    |  1 +
 src/exchangedb/pg_insert_kyc_attributes.c |  2 +-
 src/exchangedb/pg_reserves_in_insert.c    |  1 +
 6 files changed, 18 insertions(+), 9 deletions(-)

diff --git a/src/exchangedb/pg_do_age_withdraw.c 
b/src/exchangedb/pg_do_age_withdraw.c
index 99584098..970e65b5 100644
--- a/src/exchangedb/pg_do_age_withdraw.c
+++ b/src/exchangedb/pg_do_age_withdraw.c
@@ -82,6 +82,7 @@ TEH_PG_do_age_withdraw (
                                 conflict),
     GNUNET_PQ_result_spec_end
   };
+  enum GNUNET_DB_QueryStatus qs;
 
   gc = GNUNET_TIME_absolute_to_timestamp (
     GNUNET_TIME_absolute_add (now.abs_time,
@@ -98,8 +99,10 @@ TEH_PG_do_age_withdraw (
            ",conflict"
            " FROM exchange_do_age_withdraw"
            " ($1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11);");
-  return GNUNET_PQ_eval_prepared_singleton_select (pg->conn,
-                                                   "call_age_withdraw",
-                                                   params,
-                                                   rs);
+  qs = GNUNET_PQ_eval_prepared_singleton_select (pg->conn,
+                                                 "call_age_withdraw",
+                                                 params,
+                                                 rs);
+  GNUNET_PQ_cleanup_query_params_closures (params);
+  return qs;
 }
diff --git a/src/exchangedb/pg_do_deposit.c b/src/exchangedb/pg_do_deposit.c
index 1e2d1c3c..0ba45b62 100644
--- a/src/exchangedb/pg_do_deposit.c
+++ b/src/exchangedb/pg_do_deposit.c
@@ -87,6 +87,7 @@ TEH_PG_do_deposit (
                                 ctr_conflict),
     GNUNET_PQ_result_spec_end
   };
+  enum GNUNET_DB_QueryStatus qs;
 
   for (unsigned int i = 0; i < bd->num_cdis; i++)
   {
@@ -109,8 +110,10 @@ TEH_PG_do_deposit (
            ",out_conflict AS conflicted"
            " FROM exchange_do_deposit"
            " ($1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16);");
-  return GNUNET_PQ_eval_prepared_singleton_select (pg->conn,
-                                                   "call_deposit",
-                                                   params,
-                                                   rs);
+  qs = GNUNET_PQ_eval_prepared_singleton_select (pg->conn,
+                                                 "call_deposit",
+                                                 params,
+                                                 rs);
+  GNUNET_PQ_cleanup_query_params_closures (params);
+  return qs;
 }
diff --git a/src/exchangedb/pg_get_link_data.c 
b/src/exchangedb/pg_get_link_data.c
index a110c491..1b0cb3e2 100644
--- a/src/exchangedb/pg_get_link_data.c
+++ b/src/exchangedb/pg_get_link_data.c
@@ -69,6 +69,7 @@ free_link_data_list (struct TALER_EXCHANGEDB_LinkList *ldl)
     next = ldl->next;
     TALER_denom_pub_free (&ldl->denom_pub);
     TALER_blinded_denom_sig_free (&ldl->ev_sig);
+    TALER_denom_ewv_free (&ldl->alg_values);
     GNUNET_free (ldl);
     ldl = next;
   }
diff --git a/src/exchangedb/pg_get_refresh_reveal.c 
b/src/exchangedb/pg_get_refresh_reveal.c
index c0e3066d..08d4b21a 100644
--- a/src/exchangedb/pg_get_refresh_reveal.c
+++ b/src/exchangedb/pg_get_refresh_reveal.c
@@ -206,6 +206,7 @@ cleanup:
 
     TALER_blinded_denom_sig_free (&rrc->coin_sig);
     TALER_blinded_planchet_free (&rrc->blinded_planchet);
+    TALER_denom_ewv_free (&rrc->exchange_vals);
   }
   GNUNET_free (grctx.rrcs);
   return qs;
diff --git a/src/exchangedb/pg_insert_kyc_attributes.c 
b/src/exchangedb/pg_insert_kyc_attributes.c
index bdddd020..8b3cf84c 100644
--- a/src/exchangedb/pg_insert_kyc_attributes.c
+++ b/src/exchangedb/pg_insert_kyc_attributes.c
@@ -99,9 +99,9 @@ TEH_PG_insert_kyc_attributes (
                                                  "insert_kyc_attributes",
                                                  params,
                                                  rs);
+  GNUNET_PQ_cleanup_query_params_closures (params);
   GNUNET_free (kyc_completed_notify_s);
   GNUNET_PQ_event_do_poll (pg->conn);
-
   if (qs < 0)
     return qs;
   if (! ok)
diff --git a/src/exchangedb/pg_reserves_in_insert.c 
b/src/exchangedb/pg_reserves_in_insert.c
index 1b854045..17cb496b 100644
--- a/src/exchangedb/pg_reserves_in_insert.c
+++ b/src/exchangedb/pg_reserves_in_insert.c
@@ -246,6 +246,7 @@ TEH_PG_reserves_in_insert (
                                                params,
                                                &helper_cb,
                                                &ctx);
+    GNUNET_PQ_cleanup_query_params_closures (params);
     if ( (qs < 0) ||
          (GNUNET_OK != ctx.status) )
     {

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