gossipd: infrastructure to tell lightningd about local channel updates.

We want it to keep the latest, so it can make its own error msgs without
asking us.  This installs (but does not use!) the message handler.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2022-01-25 06:28:52 +10:30
parent a8bed542f7
commit 51d23ffcd3
5 changed files with 43 additions and 0 deletions

View File

@@ -253,6 +253,7 @@ struct channel *new_unsaved_channel(struct peer *peer,
= CLOSING_FEE_NEGOTIATION_STEP_UNIT_PERCENTAGE;
channel->shutdown_wrong_funding = NULL;
channel->closing_feerate_range = NULL;
channel->channel_update = NULL;
/* Channel is connected! */
channel->connected = true;
@@ -461,6 +462,7 @@ struct channel *new_channel(struct peer *peer, u64 dbid,
channel->lease_chan_max_msat = lease_chan_max_msat;
channel->lease_chan_max_ppt = lease_chan_max_ppt;
channel->blockheight_states = dup_height_states(channel, height_states);
channel->channel_update = NULL;
list_add_tail(&peer->channels, &channel->list);
channel->rr_number = peer->ld->rr_counter++;