diff options
author | Christian Grothoff <christian@grothoff.org> | 2021-08-15 19:01:17 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2021-08-15 19:01:17 +0200 |
commit | 3b90e437e26013f5570d6c216b832c7bcd740712 (patch) | |
tree | 13ab0dddb4e13c49b86b4526208f05dddfa10e95 /src/authorization | |
parent | 622eba29d8675ce12640cf513350891246fd90c8 (diff) | |
download | anastasis-3b90e437e26013f5570d6c216b832c7bcd740712.tar.gz anastasis-3b90e437e26013f5570d6c216b832c7bcd740712.tar.bz2 anastasis-3b90e437e26013f5570d6c216b832c7bcd740712.zip |
add logic to resume wire transfer checks from last checkpoint
Diffstat (limited to 'src/authorization')
-rw-r--r-- | src/authorization/anastasis-helper-authorization-iban.c | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/src/authorization/anastasis-helper-authorization-iban.c b/src/authorization/anastasis-helper-authorization-iban.c index b66d181..946b008 100644 --- a/src/authorization/anastasis-helper-authorization-iban.c +++ b/src/authorization/anastasis-helper-authorization-iban.c @@ -22,7 +22,6 @@ * - blocked on #6992 * - needs XXX_bank_service to access new facade once #6992 is implemented * - needs to load authentication information - * - needs to load 'last known' transaction from DB * - needs to add DB triggers to notify main service of inbound activity */ #include "platform.h" @@ -46,6 +45,11 @@ static struct BANK_AccountInfo *auth; /** + * Bank account payto://-URI this process is monitoring. + */ +static struct credit_account_uri; + +/** * Active request for history. */ static struct BANK_CreditHistoryHandle *hh; @@ -282,7 +286,20 @@ run (void *cls, return; } // FIXME: initialize 'auth' from cfg! + { + enum GNUNET_DB_QueryStatus qs; + qs = db_plugin->get_last_auth_iban_payment_row (db_plugin->cls, + credit_account_uri, + &latest_row_off); + if (qs < 0) + { + GNUNET_break (0); + ANASTASIS_DB_plugin_unload (db_plugin); + db_plugin = NULL; + return; + } + } GNUNET_SCHEDULER_add_shutdown (&shutdown_task, cls); ctx = GNUNET_CURL_init (&GNUNET_CURL_gnunet_scheduler_reschedule, |