mirror of
https://github.com/aljazceru/lightning.git
synced 2026-02-21 22:14:20 +01:00
lightningd: use lowball feerate for commit_tx on anchor channels.
Since we can CPFP, we don't have to track the feerate as closely. But it still needs to get in the mempool, so we use 10 sat/byte, or the 100 block estimate if that is higher. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Added: JSON-RPC: `feerates` has new fields `unilateral_anchor_close` to show the feerate used for anchor channels (currently experimental), and `unilateral_close_nonanchor_satoshis`. Changelog-Changed: JSON-RPC: `feerates` `unilateral_close_satoshis` now assumes anchor channels if enabled (currently experimental).
This commit is contained in:
@@ -68,7 +68,11 @@ static struct command_result *param_feerate_unchecked(struct command *cmd,
|
||||
return NULL;
|
||||
}
|
||||
if (json_tok_streq(buffer, tok, "unilateral_close")) {
|
||||
**feerate = unilateral_feerate(cmd->ld->topology);
|
||||
**feerate = unilateral_feerate(cmd->ld->topology, false);
|
||||
return NULL;
|
||||
}
|
||||
if (json_tok_streq(buffer, tok, "unilateral_anchor_close")) {
|
||||
**feerate = unilateral_feerate(cmd->ld->topology, true);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user