diff options
author | Christian Grothoff <christian@grothoff.org> | 2015-04-11 21:29:15 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2015-04-11 21:29:15 +0200 |
commit | 4f078c7666bfc1c2379b242c38674932dbf832ee (patch) | |
tree | 2ad069f96d69e63ed299d042511a29bd49e97a44 /src/mintdb/plugin_mintdb_common.c | |
parent | 8b321252230a2e87ec8f50cec0c344122952c387 (diff) | |
download | exchange-4f078c7666bfc1c2379b242c38674932dbf832ee.tar.gz exchange-4f078c7666bfc1c2379b242c38674932dbf832ee.tar.bz2 exchange-4f078c7666bfc1c2379b242c38674932dbf832ee.zip |
scaffolding work towards #3712
Diffstat (limited to 'src/mintdb/plugin_mintdb_common.c')
-rw-r--r-- | src/mintdb/plugin_mintdb_common.c | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/src/mintdb/plugin_mintdb_common.c b/src/mintdb/plugin_mintdb_common.c index 2bd789472..f380d7da0 100644 --- a/src/mintdb/plugin_mintdb_common.c +++ b/src/mintdb/plugin_mintdb_common.c @@ -115,4 +115,35 @@ common_free_coin_transaction_list (void *cls, } } + +/** + * Free melt commitment data. + * + * @param cls the @e cls of this struct with the plugin-specific state (unused) + * @param mc data structure to free + */ +static void +common_free_melt_commitment (void *cls, + struct TALER_MINTDB_MeltCommitment *mc) +{ + unsigned int i; + unsigned int k; + + GNUNET_free (mc->melts); + for (i=0;i<mc->num_newcoins;i++) + GNUNET_CRYPTO_rsa_public_key_free (mc->denom_pubs[i].rsa_public_key); + GNUNET_free (mc->denom_pubs); + for (k=0;k<TALER_CNC_KAPPA;k++) + { + for (i=0;i<mc->num_newcoins;i++) + { + GNUNET_free (mc->commit_coins[k][i].refresh_link); + GNUNET_free (mc->commit_coins[k][i].coin_ev); + } + GNUNET_free (mc->commit_coins[k]); + GNUNET_free (mc->commit_links[k]); + } + GNUNET_free (mc); +} + /* end of plugin_mintdb_common.c */ |