diff --git a/lightning/src/ln/channel.rs b/lightning/src/ln/channel.rs index 4529be57d82..7a7db8db075 100644 --- a/lightning/src/ln/channel.rs +++ b/lightning/src/ln/channel.rs @@ -43,7 +43,7 @@ pub struct ChannelValueStat { pub pending_outbound_htlcs_amount_msat: u64, pub pending_inbound_htlcs_amount_msat: u64, pub holding_cell_outbound_amount_msat: u64, - pub their_max_htlc_value_in_flight_msat: u64, // outgoing + pub counterparty_max_htlc_value_in_flight_msat: u64, // outgoing } enum InboundHTLCRemovalReason { @@ -242,9 +242,9 @@ pub(super) struct Channel { latest_monitor_update_id: u64, #[cfg(not(test))] - local_keys: ChanSigner, + our_keys: ChanSigner, #[cfg(test)] - pub(super) local_keys: ChanSigner, + pub(super) our_keys: ChanSigner, shutdown_pubkey: PublicKey, destination_script: Script, @@ -252,8 +252,8 @@ pub(super) struct Channel { // generation start at 0 and count up...this simplifies some parts of implementation at the // cost of others, but should really just be changed. - cur_local_commitment_transaction_number: u64, - cur_remote_commitment_transaction_number: u64, + cur_our_commtment_transaction_number: u64, + cur_counterparty_commitment_transaction_number: u64, value_to_self_msat: u64, // Excluding all pending_htlcs, excluding fees pending_inbound_htlcs: Vec, pending_outbound_htlcs: Vec, @@ -291,17 +291,17 @@ pub(super) struct Channel { // is received. holding_cell_update_fee is updated when there are additional // update_fee() during ChannelState::AwaitingRemoteRevoke. holding_cell_update_fee: Option, - next_local_htlc_id: u64, - next_remote_htlc_id: u64, + next_our_htlc_id: u64, + next_counterparty_htlc_id: u64, update_time_counter: u32, feerate_per_kw: u64, #[cfg(debug_assertions)] /// Max to_local and to_remote outputs in a locally-generated commitment transaction - max_commitment_tx_output_local: ::std::sync::Mutex<(u64, u64)>, + max_commitment_tx_output_our: ::std::sync::Mutex<(u64, u64)>, #[cfg(debug_assertions)] /// Max to_local and to_remote outputs in a remote-generated commitment transaction - max_commitment_tx_output_remote: ::std::sync::Mutex<(u64, u64)>, + max_commitment_tx_output_counterparty: ::std::sync::Mutex<(u64, u64)>, last_sent_closing_fee: Option<(u64, u64, Signature)>, // (feerate, fee, our_sig) @@ -318,38 +318,38 @@ pub(super) struct Channel { pub(super) last_block_connected: BlockHash, funding_tx_confirmations: u64, - their_dust_limit_satoshis: u64, + counterparty_dust_limit_satoshis: u64, #[cfg(test)] pub(super) our_dust_limit_satoshis: u64, #[cfg(not(test))] our_dust_limit_satoshis: u64, #[cfg(test)] - pub(super) their_max_htlc_value_in_flight_msat: u64, + pub(super) counterparty_max_htlc_value_in_flight_msat: u64, #[cfg(not(test))] - their_max_htlc_value_in_flight_msat: u64, + counterparty_max_htlc_value_in_flight_msat: u64, //get_our_max_htlc_value_in_flight_msat(): u64, /// minimum channel reserve for self to maintain - set by them. - local_channel_reserve_satoshis: u64, + our_channel_reserve_satoshis: u64, // get_remote_channel_reserve_satoshis(channel_value_sats: u64): u64 - their_htlc_minimum_msat: u64, + counterparty_htlc_minimum_msat: u64, our_htlc_minimum_msat: u64, - their_to_self_delay: u16, + counterparty_to_self_delay: u16, our_to_self_delay: u16, #[cfg(test)] - pub their_max_accepted_htlcs: u16, + pub counterparty_max_accepted_htlcs: u16, #[cfg(not(test))] - their_max_accepted_htlcs: u16, + counterparty_max_accepted_htlcs: u16, //implied by OUR_MAX_HTLCS: our_max_accepted_htlcs: u16, minimum_depth: u32, - their_pubkeys: Option, + counterparty_pubkeys: Option, - their_cur_commitment_point: Option, + counterparty_cur_commitment_point: Option, - their_prev_commitment_point: Option, - their_node_id: PublicKey, + counterparty_prev_commitment_point: Option, + counterparty_node_id: PublicKey, - their_shutdown_scriptpubkey: Option