summaryrefslogtreecommitdiff
path: root/src/exchange
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2017-05-05 13:41:32 +0200
committerChristian Grothoff <christian@grothoff.org>2017-05-05 13:41:32 +0200
commit76545519c647b66ef99391b503f5d90fd4a43cb4 (patch)
treecf7fcda13826c5b00dc4e593ab25bf155792be80 /src/exchange
parent2c05a4b278096a9f222a472c0f022c66ad367059 (diff)
downloadexchange-76545519c647b66ef99391b503f5d90fd4a43cb4.tar.gz
exchange-76545519c647b66ef99391b503f5d90fd4a43cb4.tar.bz2
exchange-76545519c647b66ef99391b503f5d90fd4a43cb4.zip
updating DB schema for new wire history operations and future auditor checks of wire transfers
Diffstat (limited to 'src/exchange')
-rw-r--r--src/exchange/taler-exchange-httpd_db.c2
-rw-r--r--src/exchange/taler-exchange-wirewatch.c18
2 files changed, 12 insertions, 8 deletions
diff --git a/src/exchange/taler-exchange-httpd_db.c b/src/exchange/taler-exchange-httpd_db.c
index dbaffc486..085438d60 100644
--- a/src/exchange/taler-exchange-httpd_db.c
+++ b/src/exchange/taler-exchange-httpd_db.c
@@ -1880,6 +1880,8 @@ TEH_DB_execute_admin_add_incoming (struct MHD_Connection *connection,
amount,
execution_time,
sender_account_details,
+ "FIXME",
+ 5,
transfer_details);
if (GNUNET_SYSERR == ret)
{
diff --git a/src/exchange/taler-exchange-wirewatch.c b/src/exchange/taler-exchange-wirewatch.c
index d343bb5dc..a7f3cd739 100644
--- a/src/exchange/taler-exchange-wirewatch.c
+++ b/src/exchange/taler-exchange-wirewatch.c
@@ -40,7 +40,7 @@
* Handle to the plugin.
*/
static struct TALER_WIRE_Plugin *wire_plugin;
-
+
/**
* Which currency is used by this exchange?
*/
@@ -63,7 +63,7 @@ static struct TALER_EXCHANGEDB_Plugin *db_plugin;
static int global_ret;
/**
- * Encoded offset in the wire transfer list that we
+ * Encoded offset in the wire transfer list that we
* processed last.
*/
static void *last_row_off;
@@ -180,7 +180,7 @@ exchange_serve_process_config ()
TALER_EXCHANGEDB_plugin_unload (db_plugin);
return GNUNET_SYSERR;
}
-
+
return GNUNET_OK;
}
@@ -248,16 +248,18 @@ history_cb (void *cls,
{
/* FIXME: need way to wire money back immediately... */
GNUNET_break (0); // not implemented
-
+
return GNUNET_OK;
}
- // FIXME: store row_off+row_off_size instead of json_t?
+ // FIXME: create json!
ret = db_plugin->reserves_in_insert (db_plugin->cls,
session,
&reserve_pub,
&details->amount,
details->execution_date,
details->account_details,
+ row_off,
+ row_off_size,
NULL /* FIXME */);
if (GNUNET_OK != ret)
{
@@ -269,7 +271,7 @@ history_cb (void *cls,
NULL);
return GNUNET_SYSERR;
}
-
+
if (last_row_off_size != row_off_size)
{
GNUNET_free_non_null (last_row_off);
@@ -291,7 +293,7 @@ static void
find_transfers (void *cls)
{
struct TALER_EXCHANGEDB_Session *session;
-
+
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Checking for incoming wire transfers\n");
@@ -357,7 +359,7 @@ run (void *cls,
global_ret = 1;
return;
}
-
+
task = GNUNET_SCHEDULER_add_now (&find_transfers,
NULL);
GNUNET_SCHEDULER_add_shutdown (&shutdown_task,