Skip to content

Commit 7177acb

Browse files
committed
Remove next_funding_txid tlv from channel read/write
We want to remove this before release so that we can work on a way to not persist this but rather get it from other persisted data and just free up the TLV. Note that the "added in 0.0.124" comment was incorrect as it was actually added in #3137 but the comment was stale so it's safe to remove.
1 parent 0c31021 commit 7177acb

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lightning/src/ln/channel.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -9507,7 +9507,6 @@ impl<SP: Deref> Writeable for Channel<SP> where SP::Target: SignerProvider {
95079507
(49, self.context.local_initiated_shutdown, option), // Added in 0.0.122
95089508
(51, is_manual_broadcast, option), // Added in 0.0.124
95099509
(53, funding_tx_broadcast_safe_event_emitted, option), // Added in 0.0.124
9510-
(55, self.context.next_funding_txid, option) // Added in 0.1.0
95119510
});
95129511

95139512
Ok(())
@@ -9797,7 +9796,6 @@ impl<'a, 'b, 'c, ES: Deref, SP: Deref> ReadableArgs<(&'a ES, &'b SP, u32, &'c Ch
97979796
let mut channel_pending_event_emitted = None;
97989797
let mut channel_ready_event_emitted = None;
97999798
let mut funding_tx_broadcast_safe_event_emitted = None;
9800-
let mut next_funding_txid = funding_transaction.as_ref().map(|tx| tx.compute_txid());
98019799

98029800
let mut user_id_high_opt: Option<u64> = None;
98039801
let mut channel_keys_id: Option<[u8; 32]> = None;
@@ -9858,7 +9856,6 @@ impl<'a, 'b, 'c, ES: Deref, SP: Deref> ReadableArgs<(&'a ES, &'b SP, u32, &'c Ch
98589856
(49, local_initiated_shutdown, option),
98599857
(51, is_manual_broadcast, option),
98609858
(53, funding_tx_broadcast_safe_event_emitted, option),
9861-
(55, next_funding_txid, option) // Added in 0.0.125
98629859
});
98639860

98649861
let (channel_keys_id, holder_signer) = if let Some(channel_keys_id) = channel_keys_id {
@@ -10119,10 +10116,13 @@ impl<'a, 'b, 'c, ES: Deref, SP: Deref> ReadableArgs<(&'a ES, &'b SP, u32, &'c Ch
1011910116

1012010117
blocked_monitor_updates: blocked_monitor_updates.unwrap(),
1012110118
is_manual_broadcast: is_manual_broadcast.unwrap_or(false),
10119+
// TODO(dual_funding): Instead of getting this from persisted value, figure it out based on the
10120+
// funding transaction and other channel state.
10121+
//
1012210122
// If we've sent `commtiment_signed` for an interactively constructed transaction
1012310123
// during a signing session, but have not received `tx_signatures` we MUST set `next_funding_txid`
1012410124
// to the txid of that interactive transaction, else we MUST NOT set it.
10125-
next_funding_txid,
10125+
next_funding_txid: None,
1012610126
},
1012710127
interactive_tx_signing_session: None,
1012810128
})

0 commit comments

Comments
 (0)