aboutsummaryrefslogtreecommitdiff
path: root/src/bank-lib
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2020-01-18 04:31:55 +0100
committerFlorian Dold <florian.dold@gmail.com>2020-01-18 04:31:55 +0100
commit5d192295616528e54c47741b835c3f748c07d3ac (patch)
tree7182dc50ad14c01d041ada571c0f0091cd40ca05 /src/bank-lib
parent0cebe32fc69324e3a656b58a528115b44e88b51c (diff)
dce: redundant args
Diffstat (limited to 'src/bank-lib')
-rw-r--r--src/bank-lib/bank_api_admin.c4
-rw-r--r--src/bank-lib/bank_api_transfer.c21
-rw-r--r--src/bank-lib/taler-bank-transfer.c1
3 files changed, 11 insertions, 15 deletions
diff --git a/src/bank-lib/bank_api_admin.c b/src/bank-lib/bank_api_admin.c
index e3c9f6898..979e0b068 100644
--- a/src/bank-lib/bank_api_admin.c
+++ b/src/bank-lib/bank_api_admin.c
@@ -161,7 +161,6 @@ handle_admin_add_incoming_finished (void *cls,
* to the operators of the bank.
*
* @param ctx curl context for the event loop
- * @param account_base_url URL of the bank (money flows into this account)
* @param auth authentication data to send to the bank
* @param reserve_pub wire transfer subject for the transfer
* @param amount amount that was deposited
@@ -174,7 +173,6 @@ handle_admin_add_incoming_finished (void *cls,
*/
struct TALER_BANK_AdminAddIncomingHandle *
TALER_BANK_admin_add_incoming (struct GNUNET_CURL_Context *ctx,
- const char *account_base_url,
const struct TALER_BANK_AuthenticationData *auth,
const struct
TALER_ReservePublicKeyP *reserve_pub,
@@ -202,7 +200,7 @@ TALER_BANK_admin_add_incoming (struct GNUNET_CURL_Context *ctx,
aai = GNUNET_new (struct TALER_BANK_AdminAddIncomingHandle);
aai->cb = res_cb;
aai->cb_cls = res_cb_cls;
- aai->request_url = TALER_url_join (account_base_url,
+ aai->request_url = TALER_url_join (auth->wire_gateway_url,
"admin/add-incoming",
NULL);
if (NULL == aai->request_url)
diff --git a/src/bank-lib/bank_api_transfer.c b/src/bank-lib/bank_api_transfer.c
index e8138adbf..61f999701 100644
--- a/src/bank-lib/bank_api_transfer.c
+++ b/src/bank-lib/bank_api_transfer.c
@@ -68,7 +68,7 @@ GNUNET_NETWORK_STRUCT_END
/**
* Prepare for exeuction of a wire transfer.
*
- * @param destination_account_url payto:// URL identifying where to send the money
+ * @param destination_account_payto_uri payto:// URL identifying where to send the money
* @param amount amount to transfer, already rounded
* @param exchange_base_url base URL of this exchange (included in subject
* to facilitate use of tracking API by merchant backend)
@@ -77,7 +77,7 @@ GNUNET_NETWORK_STRUCT_END
* @param[out] buf_size set to number of bytes in @a buf, 0 on error
*/
void
-TALER_BANK_prepare_wire_transfer (const char *destination_account_url,
+TALER_BANK_prepare_wire_transfer (const char *destination_account_payto_uri,
const struct TALER_Amount *amount,
const char *exchange_base_url,
const struct
@@ -86,7 +86,7 @@ TALER_BANK_prepare_wire_transfer (const char *destination_account_url,
size_t *buf_size)
{
struct WirePackP *wp;
- size_t d_len = strlen (destination_account_url) + 1;
+ size_t d_len = strlen (destination_account_payto_uri) + 1;
size_t u_len = strlen (exchange_base_url) + 1;
char *end;
@@ -101,7 +101,7 @@ TALER_BANK_prepare_wire_transfer (const char *destination_account_url,
wp->exchange_url_len = htonl ((uint32_t) u_len);
end = (char *) &wp[1];
memcpy (end,
- destination_account_url,
+ destination_account_payto_uri,
d_len);
memcpy (end + d_len,
exchange_base_url,
@@ -249,7 +249,6 @@ handle_transfer_finished (void *cls,
*/
struct TALER_BANK_WireExecuteHandle *
TALER_BANK_execute_wire_transfer (struct GNUNET_CURL_Context *ctx,
- const char *bank_base_url,
const struct
TALER_BANK_AuthenticationData *auth,
const void *buf,
@@ -263,7 +262,7 @@ TALER_BANK_execute_wire_transfer (struct GNUNET_CURL_Context *ctx,
const struct WirePackP *wp = buf;
uint32_t d_len;
uint32_t u_len;
- const char *destination_account_url;
+ const char *destination_account_uri;
const char *exchange_base_url;
struct TALER_Amount amount;
@@ -279,9 +278,9 @@ TALER_BANK_execute_wire_transfer (struct GNUNET_CURL_Context *ctx,
GNUNET_break (0);
return NULL;
}
- destination_account_url = (const char *) &wp[1];
- exchange_base_url = destination_account_url + d_len;
- if (NULL == bank_base_url)
+ destination_account_uri = (const char *) &wp[1];
+ exchange_base_url = destination_account_uri + d_len;
+ if (NULL == auth->wire_gateway_url)
{
GNUNET_break (0);
return NULL;
@@ -291,7 +290,7 @@ TALER_BANK_execute_wire_transfer (struct GNUNET_CURL_Context *ctx,
weh = GNUNET_new (struct TALER_BANK_WireExecuteHandle);
weh->cb = cc;
weh->cb_cls = cc_cls;
- weh->request_url = TALER_url_join (bank_base_url,
+ weh->request_url = TALER_url_join (auth->wire_gateway_url,
"transfer",
NULL);
if (NULL == weh->request_url)
@@ -306,7 +305,7 @@ TALER_BANK_execute_wire_transfer (struct GNUNET_CURL_Context *ctx,
"amount", TALER_JSON_from_amount (&amount),
"exchange_base_url", exchange_base_url,
"wtid", GNUNET_JSON_from_data_auto (&wp->wtid),
- "credit_account", destination_account_url);
+ "credit_account", destination_account_uri);
if (NULL == transfer_obj)
{
GNUNET_break (0);
diff --git a/src/bank-lib/taler-bank-transfer.c b/src/bank-lib/taler-bank-transfer.c
index c52c4b38d..692705e32 100644
--- a/src/bank-lib/taler-bank-transfer.c
+++ b/src/bank-lib/taler-bank-transfer.c
@@ -189,7 +189,6 @@ run (void *cls,
auth.details.basic.username = username;
auth.details.basic.password = password;
op = TALER_BANK_admin_add_incoming (ctx,
- account_base_url,
&auth,
&reserve_pub,
&amount,