mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-20 15:44:21 +01:00
channel: update fees after lockin.
We don't respond to fee changes until we're locked in: make sure we catch up at that point. Note that we use NORMAL fees during opening, but IMMEDIATE after, so this often sends a fee update. The tests which break, we set those feerates to be equal. This (sometimes) changes the behavior of test_permfail, as we now get an immediate commit, so that is fixed too so we always wait for that to complete. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -25,6 +25,10 @@ static void lockin_complete(struct channel *channel)
|
||||
/* We set this once they're locked in. */
|
||||
assert(channel->remote_funding_locked);
|
||||
channel_set_state(channel, CHANNELD_AWAITING_LOCKIN, CHANNELD_NORMAL);
|
||||
|
||||
/* Fees might have changed (and we use IMMEDIATE once we're funded),
|
||||
* so update now. */
|
||||
try_update_feerates(channel->peer->ld, channel);
|
||||
}
|
||||
|
||||
/* We were informed by channeld that it announced the channel and sent
|
||||
|
||||
Reference in New Issue
Block a user