aboutsummaryrefslogtreecommitdiff
path: root/src/mintdb
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2015-07-09 22:29:10 +0200
committerChristian Grothoff <christian@grothoff.org>2015-07-09 22:29:10 +0200
commit1e7bef9762644445fd34a554488711b3881c699a (patch)
treeb42b24f4888e680b349c3ead2f2e208892fb4ed4 /src/mintdb
parentbe535b68e1c5911c9ec011a0d24714d0f4b42377 (diff)
-fix leaks
Diffstat (limited to 'src/mintdb')
-rw-r--r--src/mintdb/plugin_mintdb_postgres.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mintdb/plugin_mintdb_postgres.c b/src/mintdb/plugin_mintdb_postgres.c
index f2bc83677..8737809bc 100644
--- a/src/mintdb/plugin_mintdb_postgres.c
+++ b/src/mintdb/plugin_mintdb_postgres.c
@@ -3030,6 +3030,7 @@ postgres_get_coin_transactions (void *cls,
if (PGRES_TUPLES_OK != PQresultStatus (result))
{
QUERY_ERR (result);
+ PQclear (result);
goto cleanup;
}
nrows = PQntuples (result);
@@ -3072,6 +3073,7 @@ postgres_get_coin_transactions (void *cls,
{
GNUNET_break (0);
GNUNET_free (deposit);
+ PQclear (result);
goto cleanup;
}
deposit->coin.coin_pub = *coin_pub;
@@ -3083,6 +3085,7 @@ postgres_get_coin_transactions (void *cls,
head = tl;
continue;
}
+ PQclear (result);
}
/* Handle refreshing */
{
@@ -3129,6 +3132,7 @@ postgres_get_coin_transactions (void *cls,
{
GNUNET_break (0);
GNUNET_free (melt);
+ PQclear (result);
goto cleanup;
}
}
@@ -3139,6 +3143,7 @@ postgres_get_coin_transactions (void *cls,
head = tl;
continue;
}
+ PQclear (result);
}
/* FIXME: Handle locked coins (#3625) */
return head;