diff options
author | Christian Grothoff <christian@grothoff.org> | 2017-04-20 09:04:20 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2017-04-20 09:04:20 +0200 |
commit | 92d9ec69e6d8e9f7eb0be0d6a7f67444189b319e (patch) | |
tree | eb4c2c115b6d1e6561bb81bd16ccd56b93923269 /src/exchangedb/plugin_exchangedb_common.c | |
parent | 487237381dc81c16878b2e3faaac37777b6dd7bf (diff) |
expand testcase to cover new DB API
Diffstat (limited to 'src/exchangedb/plugin_exchangedb_common.c')
-rw-r--r-- | src/exchangedb/plugin_exchangedb_common.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/exchangedb/plugin_exchangedb_common.c b/src/exchangedb/plugin_exchangedb_common.c index b97aa08c2..ba182d425 100644 --- a/src/exchangedb/plugin_exchangedb_common.c +++ b/src/exchangedb/plugin_exchangedb_common.c @@ -34,13 +34,13 @@ common_free_reserve_history (void *cls, struct TALER_EXCHANGEDB_CollectableBlindcoin *cbc; struct TALER_EXCHANGEDB_Payback *payback; struct TALER_EXCHANGEDB_ReserveHistory *backref; - + struct TALER_EXCHANGEDB_ClosingTransfer *closing; + while (NULL != rh) { switch(rh->type) { case TALER_EXCHANGEDB_RO_BANK_TO_EXCHANGE: - case TALER_EXCHANGEDB_RO_EXCHANGE_TO_BANK: bt = rh->details.bank; if (NULL != bt->sender_account_details) json_decref (bt->sender_account_details); @@ -60,6 +60,14 @@ common_free_reserve_history (void *cls, GNUNET_CRYPTO_rsa_public_key_free (payback->coin.denom_pub.rsa_public_key); GNUNET_free (payback); break; + case TALER_EXCHANGEDB_RO_EXCHANGE_TO_BANK: + closing = rh->details.closing; + if (NULL != closing->receiver_account_details) + json_decref (closing->receiver_account_details); + if (NULL != closing->transfer_details) + json_decref (closing->transfer_details); + GNUNET_free (closing); + break; } backref = rh; rh = rh->next; |