From: Valentine Wallace Date: Wed, 13 Dec 2023 21:43:27 +0000 (-0500) Subject: Rename InboundOnionPayload::BlindedReceive::outgoing_cltv_value. X-Git-Tag: v0.0.120~9^2~6 X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=commitdiff_plain;h=7c3ef195c4380cc49dbaa4ce896a33099bbded22;p=rust-lightning Rename InboundOnionPayload::BlindedReceive::outgoing_cltv_value. There is no outgoing HTLC for received HTLCs, so rename to be more accurate. --- diff --git a/lightning/src/ln/msgs.rs b/lightning/src/ln/msgs.rs index 574f1b7cf..d9b5cda4b 100644 --- a/lightning/src/ln/msgs.rs +++ b/lightning/src/ln/msgs.rs @@ -1719,7 +1719,7 @@ mod fuzzy_internal_msgs { BlindedReceive { amt_msat: u64, total_msat: u64, - outgoing_cltv_value: u32, + cltv_expiry_height: u32, payment_secret: PaymentSecret, payment_constraints: PaymentConstraints, intro_node_blinding_point: Option, @@ -2403,7 +2403,7 @@ impl ReadableArgs<(Option, &NS)> for InboundOnionPayload w Ok(Self::BlindedReceive { amt_msat: amt.ok_or(DecodeError::InvalidValue)?, total_msat: total_msat.ok_or(DecodeError::InvalidValue)?, - outgoing_cltv_value: cltv_value.ok_or(DecodeError::InvalidValue)?, + cltv_expiry_height: cltv_value.ok_or(DecodeError::InvalidValue)?, payment_secret, payment_constraints, intro_node_blinding_point, diff --git a/lightning/src/ln/onion_payment.rs b/lightning/src/ln/onion_payment.rs index ae602fb11..cba3ef0fb 100644 --- a/lightning/src/ln/onion_payment.rs +++ b/lightning/src/ln/onion_payment.rs @@ -131,7 +131,7 @@ pub(super) fn create_recv_pending_htlc_info( (payment_data, keysend_preimage, custom_tlvs, amt_msat, cltv_expiry_height, payment_metadata, false), msgs::InboundOnionPayload::BlindedReceive { - amt_msat, total_msat, outgoing_cltv_value, payment_secret, intro_node_blinding_point, + amt_msat, total_msat, cltv_expiry_height, payment_secret, intro_node_blinding_point, payment_constraints, .. } => { check_blinded_payment_constraints(amt_msat, cltv_expiry, &payment_constraints) @@ -143,7 +143,7 @@ pub(super) fn create_recv_pending_htlc_info( } })?; let payment_data = msgs::FinalOnionHopData { payment_secret, total_msat }; - (Some(payment_data), None, Vec::new(), amt_msat, outgoing_cltv_value, None, + (Some(payment_data), None, Vec::new(), amt_msat, cltv_expiry_height, None, intro_node_blinding_point.is_none()) } msgs::InboundOnionPayload::Forward { .. } => {