File tree 2 files changed +8
-4
lines changed
2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -1203,6 +1203,10 @@ impl<ChanSigner: ChannelKeys> ChannelMonitor<ChanSigner> {
1203
1203
feerate_per_kw : initial_local_commitment_tx. feerate_per_kw ,
1204
1204
htlc_outputs : Vec :: new ( ) , // There are never any HTLCs in the initial commitment transactions
1205
1205
} ;
1206
+
1207
+ let mut outputs_to_watch = HashMap :: new ( ) ;
1208
+ outputs_to_watch. insert ( funding_info. 0 . txid , vec ! [ funding_info. 1 . clone( ) ] ) ;
1209
+
1206
1210
// Returning a monitor error before updating tracking points means in case of using
1207
1211
// a concurrent watchtower implementation for same channel, if this one doesn't
1208
1212
// reject update as we do, you MAY have the latest local valid commitment tx onchain
@@ -1246,7 +1250,7 @@ impl<ChanSigner: ChannelKeys> ChannelMonitor<ChanSigner> {
1246
1250
pending_events : Vec :: new ( ) ,
1247
1251
1248
1252
onchain_events_waiting_threshold_conf : HashMap :: new ( ) ,
1249
- outputs_to_watch : HashMap :: new ( ) ,
1253
+ outputs_to_watch,
1250
1254
1251
1255
onchain_tx_handler,
1252
1256
Original file line number Diff line number Diff line change @@ -66,9 +66,9 @@ pub trait Watch: Send + Sync {
66
66
/// Watches a channel identified by `funding_txo` using `monitor`.
67
67
///
68
68
/// Implementations are responsible for watching the chain for the funding transaction along
69
- /// with spends of its output and any outputs returned by [`get_outputs_to_watch`]. In practice,
70
- /// this means calling [`block_connected`] and [`block_disconnected`] on the monitor and
71
- /// including all such transactions that meet this criteria.
69
+ /// with any spends of outputs returned by [`get_outputs_to_watch`]. In practice, this means
70
+ /// calling [`block_connected`] and [`block_disconnected`] on the monitor and including all such
71
+ /// transactions that meet this criteria.
72
72
///
73
73
/// [`get_outputs_to_watch`]: ../ln/channelmonitor/struct.ChannelMonitor.html#method.get_outputs_to_watch
74
74
/// [`block_connected`]: ../ln/channelmonitor/struct.ChannelMonitor.html#method.block_connected
You can’t perform that action at this time.
0 commit comments