summaryrefslogtreecommitdiff
path: root/src/exchange/taler-exchange-httpd_db.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/exchange/taler-exchange-httpd_db.c')
-rw-r--r--src/exchange/taler-exchange-httpd_db.c64
1 files changed, 0 insertions, 64 deletions
diff --git a/src/exchange/taler-exchange-httpd_db.c b/src/exchange/taler-exchange-httpd_db.c
index bed2a7fb7..9871b7f34 100644
--- a/src/exchange/taler-exchange-httpd_db.c
+++ b/src/exchange/taler-exchange-httpd_db.c
@@ -1145,68 +1145,4 @@ TEH_DB_execute_refresh_link (struct MHD_Connection *connection,
}
-/**
- * Add an incoming transaction to the database. Checks if the
- * transaction is fresh (not a duplicate) and if so adds it to
- * the database.
- *
- * @param connection the MHD connection to handle
- * @param reserve_pub public key of the reserve
- * @param amount amount to add to the reserve
- * @param execution_time when did we receive the wire transfer
- * @param sender_account_details which account send the funds
- * @param transfer_details information that uniquely identifies the transfer
- * @return MHD result code
- */
-int
-TEH_DB_execute_admin_add_incoming (struct MHD_Connection *connection,
- const struct TALER_ReservePublicKeyP *reserve_pub,
- const struct TALER_Amount *amount,
- struct GNUNET_TIME_Absolute execution_time,
- const json_t *sender_account_details,
- const json_t *transfer_details)
-{
- struct TALER_EXCHANGEDB_Session *session;
- int ret;
- void *json_str;
-
- if (NULL == (session = TEH_plugin->get_session (TEH_plugin->cls)))
- {
- GNUNET_break (0);
- return TEH_RESPONSE_reply_internal_db_error (connection,
- TALER_EC_DB_SETUP_FAILED);
- }
- json_str = json_dumps (transfer_details,
- JSON_INDENT(2));
- if (NULL == json_str)
- {
- GNUNET_break (0);
- return TEH_RESPONSE_reply_internal_db_error (connection,
- TALER_EC_PARSER_OUT_OF_MEMORY);
- }
- ret = TEH_plugin->reserves_in_insert (TEH_plugin->cls,
- session,
- reserve_pub,
- amount,
- execution_time,
- sender_account_details,
- json_str,
- strlen (json_str));
- free (json_str);
- if (GNUNET_SYSERR == ret)
- {
- GNUNET_break (0);
- return TEH_RESPONSE_reply_internal_db_error (connection,
- TALER_EC_ADMIN_ADD_INCOMING_DB_STORE);
- }
- return TEH_RESPONSE_reply_json_pack (connection,
- MHD_HTTP_OK,
- "{s:s}",
- "status",
- (GNUNET_OK == ret)
- ? "NEW"
- : "DUP");
-}
-
-
/* end of taler-exchange-httpd_db.c */