From 7e395e0265c8cad41dd23ba4d6804c158cbba99e Mon Sep 17 00:00:00 2001 From: Antoine Riard Date: Sat, 21 Mar 2020 15:48:11 -0400 Subject: [PATCH] Remove per_input_material introduce in commit 0011713 Caching of input material for HTLC transaction was introducted prevently but since then API (InputMaterial) has changed between ChannelMonitor and OnchainTxHandler --- lightning/src/ln/channelmonitor.rs | 6 ------ 1 file changed, 6 deletions(-) diff --git a/lightning/src/ln/channelmonitor.rs b/lightning/src/ln/channelmonitor.rs index 4bdc56674..fa5e35902 100644 --- a/lightning/src/ln/channelmonitor.rs +++ b/lightning/src/ln/channelmonitor.rs @@ -1708,9 +1708,6 @@ impl ChannelMonitor { Err(_) => continue, }; - let mut per_input_material = HashMap::with_capacity(1); - per_input_material.insert(htlc_timeout_tx.input[0].previous_output, InputMaterial::LocalHTLC { witness_script: htlc_script, sigs: (*their_sig, our_sig), preimage: None, amount: htlc.amount_msat / 1000}); - //TODO: with option_simplified_commitment track outpoint too log_trace!(self, "Outpoint {}:{} is being being claimed", htlc_timeout_tx.input[0].previous_output.vout, htlc_timeout_tx.input[0].previous_output.txid); res.push(htlc_timeout_tx); } else { @@ -1723,9 +1720,6 @@ impl ChannelMonitor { Err(_) => continue, }; - let mut per_input_material = HashMap::with_capacity(1); - per_input_material.insert(htlc_success_tx.input[0].previous_output, InputMaterial::LocalHTLC { witness_script: htlc_script, sigs: (*their_sig, our_sig), preimage: Some(*payment_preimage), amount: htlc.amount_msat / 1000}); - //TODO: with option_simplified_commitment track outpoint too log_trace!(self, "Outpoint {}:{} is being being claimed", htlc_success_tx.input[0].previous_output.vout, htlc_success_tx.input[0].previous_output.txid); res.push(htlc_success_tx); } -- 2.39.5