[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [taler-merchant] branch master updated: return error instea
From: |
gnunet |
Subject: |
[GNUnet-SVN] [taler-merchant] branch master updated: return error instead of crashing on /pay with zero coins |
Date: |
Tue, 23 Jan 2018 19:22:16 +0100 |
This is an automated email from the git hooks/post-receive script.
dold pushed a commit to branch master
in repository merchant.
The following commit(s) were added to refs/heads/master by this push:
new be835f4 return error instead of crashing on /pay with zero coins
be835f4 is described below
commit be835f4bb16fa956e03127f294e888f6cf1f8701
Author: Florian Dold <address@hidden>
AuthorDate: Tue Jan 23 19:21:56 2018 +0100
return error instead of crashing on /pay with zero coins
---
src/backend/taler-merchant-httpd_pay.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/backend/taler-merchant-httpd_pay.c
b/src/backend/taler-merchant-httpd_pay.c
index 7f9a234..ca96cae 100644
--- a/src/backend/taler-merchant-httpd_pay.c
+++ b/src/backend/taler-merchant-httpd_pay.c
@@ -625,7 +625,9 @@ check_payment_sufficient (struct PayContext *pc)
struct TALER_Amount wire_fee_customer_contribution;
struct TALER_Amount total_wire_fee;
- GNUNET_assert (0 != pc->coins_cnt);
+ if (0 == pc->coins_cnt)
+ return TALER_EC_PAY_PAYMENT_INSUFFICIENT;
+
acc_fee = pc->dc[0].deposit_fee;
total_wire_fee = pc->dc[0].wire_fee;
acc_amount = pc->dc[0].amount_with_fee;
--
To stop receiving notification emails like this one, please contact
address@hidden
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] [taler-merchant] branch master updated: return error instead of crashing on /pay with zero coins,
gnunet <=