diff options
author | Marcello Stanisci <stanisci.m@gmail.com> | 2018-10-22 16:59:09 +0200 |
---|---|---|
committer | Marcello Stanisci <stanisci.m@gmail.com> | 2018-10-22 16:59:09 +0200 |
commit | 60c533562cdac20a7343daef654144f161f348eb (patch) | |
tree | c546a31d8a4348e48b573c2fc94ecd702f862b9b /src/exchange-lib/exchange_api_deposit.c | |
parent | e83964badb5c266992f5b1312b31aa6a14d392e5 (diff) | |
download | exchange-60c533562cdac20a7343daef654144f161f348eb.tar.xz |
Fix compiler warnings.
This reverts changes made in b0d00823eb96de733510354. The warnings
are fixed by changing the functions signatures, instead of casting
their pointers.
Diffstat (limited to 'src/exchange-lib/exchange_api_deposit.c')
-rw-r--r-- | src/exchange-lib/exchange_api_deposit.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/src/exchange-lib/exchange_api_deposit.c b/src/exchange-lib/exchange_api_deposit.c index 71a1f2d68..c388e6816 100644 --- a/src/exchange-lib/exchange_api_deposit.c +++ b/src/exchange-lib/exchange_api_deposit.c @@ -193,16 +193,17 @@ verify_deposit_signature_forbidden (const struct TALER_EXCHANGE_DepositHandle *d * * @param cls the `struct TALER_EXCHANGE_DepositHandle` * @param response_code HTTP response code, 0 on error - * @param json parsed JSON result, NULL on error + * @param response parsed JSON result, NULL on error */ static void handle_deposit_finished (void *cls, long response_code, - const json_t *json) + const void *response) { struct TALER_EXCHANGE_DepositHandle *dh = cls; struct TALER_ExchangePublicKeyP exchange_pub; struct TALER_ExchangePublicKeyP *ep = NULL; + const json_t *j = response; dh->job = NULL; switch (response_code) @@ -212,7 +213,7 @@ handle_deposit_finished (void *cls, case MHD_HTTP_OK: if (GNUNET_OK != verify_deposit_signature_ok (dh, - json, + j, &exchange_pub)) { GNUNET_break_op (0); @@ -231,7 +232,7 @@ handle_deposit_finished (void *cls, /* Double spending; check signatures on transaction history */ if (GNUNET_OK != verify_deposit_signature_forbidden (dh, - json)) + j)) { GNUNET_break_op (0); response_code = 0; @@ -261,9 +262,9 @@ handle_deposit_finished (void *cls, } dh->cb (dh->cb_cls, response_code, - TALER_JSON_get_error_code (json), + TALER_JSON_get_error_code (j), ep, - json); + j); TALER_EXCHANGE_deposit_cancel (dh); } @@ -511,7 +512,7 @@ TALER_EXCHANGE_deposit (struct TALER_EXCHANGE_Handle *exchange, dh->job = GNUNET_CURL_job_add (ctx, eh, GNUNET_YES, - (GC_JCC) &handle_deposit_finished, + &handle_deposit_finished, dh); return dh; } |