summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSebastian <sebasjm@gmail.com>2021-07-22 13:55:57 -0300
committerSebastian <sebasjm@gmail.com>2021-07-22 13:56:30 -0300
commit334b2f954b029c85244472e2e22d1a84b9b592db (patch)
tree7278abb4c26aa6990b0af5eb86188361577194ac /src
parent827b3c9d2c5e2df415d48d1e5ae8a7feb2f67e8d (diff)
downloadmerchant-334b2f954b029c85244472e2e22d1a84b9b592db.tar.gz
merchant-334b2f954b029c85244472e2e22d1a84b9b592db.tar.bz2
merchant-334b2f954b029c85244472e2e22d1a84b9b592db.zip
check no coins
Diffstat (limited to 'src')
-rw-r--r--src/backend/taler-merchant-httpd_post-orders-ID-pay.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/backend/taler-merchant-httpd_post-orders-ID-pay.c b/src/backend/taler-merchant-httpd_post-orders-ID-pay.c
index 71457c85..94f40158 100644
--- a/src/backend/taler-merchant-httpd_post-orders-ID-pay.c
+++ b/src/backend/taler-merchant-httpd_post-orders-ID-pay.c
@@ -1078,7 +1078,12 @@ check_payment_sufficient (struct PayContext *pc)
struct TALER_Amount total_wire_fee;
struct TALER_Amount total_needed;
- GNUNET_assert (0 != pc->coins_cnt);
+ if (0 == pc->coins_cnt)
+ {
+ return ((0 == pc->amount.value) &&
+ (0 == pc->amount.fraction));
+ }
+
acc_fee = pc->dc[0].deposit_fee;
total_wire_fee = pc->dc[0].wire_fee;
acc_amount = pc->dc[0].amount_with_fee;