doc: include recent BOLT recommendation on grace period.

This includes the recommendation that we use 10 minute grace period,
so add quotes to where we use that.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell 2022-09-10 11:44:31 +09:30
parent 3cc6d0ec2c
commit 4ca1203eb8
2 changed files with 8 additions and 1 deletions

View File

@ -2601,6 +2601,10 @@ static struct command_result *json_setchannelfee(struct command *cmd,
&base, cmd->ld->config.fee_base),
p_opt_def("ppm", param_number, &ppm,
cmd->ld->config.fee_per_satoshi),
/* BOLT #7:
* If it creates a new `channel_update` with updated channel parameters:
* - SHOULD keep accepting the previous channel parameters for 10 minutes
*/
p_opt_def("enforcedelay", param_number, &delaysecs, 600),
NULL))
return command_param_failed();

View File

@ -720,7 +720,10 @@ static void forward_htlc(struct htlc_in *hin,
if (!check_fwd_amount(hin, amt_to_forward, hin->msat,
next->feerate_base,
next->feerate_ppm)) {
/* Are we in old-fee grace-period? */
/* BOLT #7:
* - If it creates a new `channel_update` with updated channel parameters:
* - SHOULD keep accepting the previous channel parameters for 10 minutes
*/
if (!time_before(time_now(), next->old_feerate_timeout)
|| !check_fwd_amount(hin, amt_to_forward, hin->msat,
next->old_feerate_base,