aboutsummaryrefslogtreecommitdiff
path: root/src/exchange-tools/taler-exchange-dbinit.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2020-03-07 12:23:32 +0100
committerChristian Grothoff <christian@grothoff.org>2020-03-07 12:23:32 +0100
commit20a7d8fc081c71d83d77b39c681dbfd9337aa97a (patch)
tree85fa33f910f095d2a7c228abecf6290e2b13a9e6 /src/exchange-tools/taler-exchange-dbinit.c
parent42bc3bc4373fe77807f12a89e1c2d118729a0a7f (diff)
merge taler-wire and taler-bank-transfer tools, they are very related and otherwise duplicate lots of logic; also enable both credit and debit histories to be shown
Diffstat (limited to 'src/exchange-tools/taler-exchange-dbinit.c')
-rw-r--r--src/exchange-tools/taler-exchange-dbinit.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/exchange-tools/taler-exchange-dbinit.c b/src/exchange-tools/taler-exchange-dbinit.c
index d7c21ad9c..d10b2ebcd 100644
--- a/src/exchange-tools/taler-exchange-dbinit.c
+++ b/src/exchange-tools/taler-exchange-dbinit.c
@@ -66,7 +66,13 @@ run (void *cls,
return;
}
if (reset_db)
- (void) plugin->drop_tables (plugin->cls);
+ {
+ if (GNUNET_OK != plugin->drop_tables (plugin->cls))
+ {
+ GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
+ "Could not drop tables. Either database was not yet initialized, or permission denied. Consult the logs. Will still try to create new tables.\n");
+ }
+ }
if (GNUNET_OK !=
plugin->create_tables (plugin->cls))
{
@@ -79,8 +85,10 @@ run (void *cls,
if (gc_db)
{
if (GNUNET_SYSERR == plugin->gc (plugin->cls))
+ {
fprintf (stderr,
"Garbage collection failed!\n");
+ }
}
TALER_EXCHANGEDB_plugin_unload (plugin);
}