From 8ff8c7b8c7015970c65849e0550ed4a0e54be2ad Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 18 May 2016 17:19:32 +0200 Subject: fix table dropping logic to ensure testcases run in fresh environment --- src/exchangedb/test_exchangedb.c | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) (limited to 'src/exchangedb/test_exchangedb.c') diff --git a/src/exchangedb/test_exchangedb.c b/src/exchangedb/test_exchangedb.c index 3169f06db..9b84d739d 100644 --- a/src/exchangedb/test_exchangedb.c +++ b/src/exchangedb/test_exchangedb.c @@ -846,23 +846,7 @@ run (void *cls) result = 77; return; } - if (GNUNET_OK != - plugin->create_tables (plugin->cls)) - { - result = 77; - goto drop; - } - if (NULL != - (session = plugin->get_session (plugin->cls))) - { - if (GNUNET_OK != - plugin->drop_tables (plugin->cls, - session)) - { - result = 77; - goto drop; - } - } + (void) plugin->drop_tables (plugin->cls); if (GNUNET_OK != plugin->create_tables (plugin->cls)) { @@ -1283,10 +1267,8 @@ run (void *cls) plugin->free_reserve_history (plugin->cls, rh); rh = NULL; - if (NULL != session) - GNUNET_break (GNUNET_OK == - plugin->drop_tables (plugin->cls, - session)); + GNUNET_break (GNUNET_OK == + plugin->drop_tables (plugin->cls)); if (NULL != dkp) destroy_denom_key_pair (dkp); if (NULL != cbc.sig.rsa_signature) -- cgit v1.2.3