Browse Source

paymod: Inherit exemptfee modifier data on retry

mpp
Christian Decker 5 years ago
committed by Rusty Russell
parent
commit
6f40cb0202
  1. 10
      plugins/libplugin-pay.c

10
plugins/libplugin-pay.c

@ -1645,9 +1645,13 @@ REGISTER_PAYMENT_MODIFIER(routehints, struct routehints_data *,
static struct exemptfee_data *exemptfee_data_init(struct payment *p)
{
struct exemptfee_data *d = tal(p, struct exemptfee_data);
d->amount = AMOUNT_MSAT(5000);
return d;
if (p->parent == NULL) {
struct exemptfee_data *d = tal(p, struct exemptfee_data);
d->amount = AMOUNT_MSAT(5000);
return d;
} else {
return payment_mod_exemptfee_get_data(p->parent);
}
}
static void exemptfee_cb(struct exemptfee_data *d, struct payment *p)

Loading…
Cancel
Save