htlcswitch+peer: notify inactive link event when htlcManager exits

This commit is contained in:
yyforyongyu
2022-11-24 06:58:33 +08:00
parent ced8833895
commit f632a58b3b
5 changed files with 34 additions and 20 deletions

View File

@@ -941,6 +941,7 @@ func (p *Brontide) addLink(chanPoint *wire.OutPoint,
towerClient = p.cfg.TowerClient
}
//nolint:lll
linkCfg := htlcswitch.ChannelLinkConfig{
Peer: p,
DecodeHopIterators: p.cfg.Sphinx.DecodeHopIterators,
@@ -976,6 +977,7 @@ func (p *Brontide) addLink(chanPoint *wire.OutPoint,
NotifyActiveLink: p.cfg.ChannelNotifier.NotifyActiveLinkEvent,
NotifyActiveChannel: p.cfg.ChannelNotifier.NotifyActiveChannelEvent,
NotifyInactiveChannel: p.cfg.ChannelNotifier.NotifyInactiveChannelEvent,
NotifyInactiveLinkEvent: p.cfg.ChannelNotifier.NotifyInactiveLinkEvent,
HtlcNotifier: p.cfg.HtlcNotifier,
GetAliases: p.cfg.GetAliases,
}