summaryrefslogtreecommitdiff
path: root/src/exchange-lib/exchange_api_refund.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2016-05-21 19:22:03 +0200
committerChristian Grothoff <christian@grothoff.org>2016-05-21 19:22:03 +0200
commit8dfb3b87b47ca2d25f6bdcbdfa2acc517fbe6ae2 (patch)
tree913b31d9e4c59050d68214298801403e293bf344 /src/exchange-lib/exchange_api_refund.c
parent9160245167ded9b2b7c11716dfa1a1e8887187f4 (diff)
downloadexchange-8dfb3b87b47ca2d25f6bdcbdfa2acc517fbe6ae2.tar.gz
exchange-8dfb3b87b47ca2d25f6bdcbdfa2acc517fbe6ae2.tar.bz2
exchange-8dfb3b87b47ca2d25f6bdcbdfa2acc517fbe6ae2.zip
testing refund, fixing bugs, refund test passes
Diffstat (limited to 'src/exchange-lib/exchange_api_refund.c')
-rw-r--r--src/exchange-lib/exchange_api_refund.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/exchange-lib/exchange_api_refund.c b/src/exchange-lib/exchange_api_refund.c
index 82ae5e8ab..3a840c7c4 100644
--- a/src/exchange-lib/exchange_api_refund.c
+++ b/src/exchange-lib/exchange_api_refund.c
@@ -169,6 +169,10 @@ handle_refund_finished (void *cls,
/* Nothing really to verify, this should never
happen, we should pass the JSON reply to the application */
break;
+ case MHD_HTTP_GONE:
+ /* Kind of normal: the money was already sent to the merchant
+ (it was too late for the refund). */
+ break;
case MHD_HTTP_INTERNAL_SERVER_ERROR:
/* Server had an internal issue; we should retry, but this API
leaves this to the application */
@@ -266,7 +270,7 @@ TALER_EXCHANGE_refund (struct TALER_EXCHANGE_Handle *exchange,
" s:I, s:I," /* transaction id, rtransaction id */
" s:o, s:o}", /* merchant_pub, merchant_sig */
"refund_amount", TALER_JSON_from_amount (amount),
- "refund_fee", TALER_JSON_from_amount (amount),
+ "refund_fee", TALER_JSON_from_amount (refund_fee),
"H_contract", GNUNET_JSON_from_data_auto (h_contract),
"coin_pub", GNUNET_JSON_from_data_auto (coin_pub),
"transaction_id", (json_int_t) transaction_id,