@@ -3297,7 +3297,7 @@ macro_rules! handle_monitor_update_completion {
3297
3297
}
3298
3298
$self.finalize_claims(updates.finalized_claimed_htlcs);
3299
3299
for failure in updates.failed_htlcs.drain(..) {
3300
- let receiver = HTLCHandlingType::NextHopChannel { node_id: Some(counterparty_node_id), channel_id };
3300
+ let receiver = HTLCHandlingType::ForwardFailed { node_id: Some(counterparty_node_id), channel_id };
3301
3301
$self.fail_htlc_backwards_internal(&failure.0, &failure.1, &failure.2, receiver);
3302
3302
}
3303
3303
} }
@@ -3923,7 +3923,7 @@ where
3923
3923
for htlc_source in failed_htlcs.drain(..) {
3924
3924
let failure_reason = LocalHTLCFailureReason::DroppedPending;
3925
3925
let reason = HTLCFailReason::from_failure_code(failure_reason);
3926
- let receiver = HTLCHandlingType::NextHopChannel { node_id: Some(*counterparty_node_id), channel_id: *channel_id };
3926
+ let receiver = HTLCHandlingType::ForwardFailed { node_id: Some(*counterparty_node_id), channel_id: *channel_id };
3927
3927
self.fail_htlc_backwards_internal(&htlc_source.0, &htlc_source.1, &reason, receiver);
3928
3928
}
3929
3929
@@ -4047,7 +4047,7 @@ where
4047
4047
let (source, payment_hash, counterparty_node_id, channel_id) = htlc_source;
4048
4048
let failure_reason = LocalHTLCFailureReason::DroppedPending;
4049
4049
let reason = HTLCFailReason::from_failure_code(failure_reason);
4050
- let receiver = HTLCHandlingType::NextHopChannel { node_id: Some(counterparty_node_id), channel_id };
4050
+ let receiver = HTLCHandlingType::ForwardFailed { node_id: Some(counterparty_node_id), channel_id };
4051
4051
self.fail_htlc_backwards_internal(&source, &payment_hash, &reason, receiver);
4052
4052
}
4053
4053
if let Some((_, funding_txo, _channel_id, monitor_update)) = shutdown_res.monitor_update {
@@ -5745,7 +5745,7 @@ where
5745
5745
if let Some(outgoing_scid) = outgoing_scid_opt {
5746
5746
match self.short_to_chan_info.read().unwrap().get(&outgoing_scid) {
5747
5747
Some((outgoing_counterparty_node_id, outgoing_channel_id)) =>
5748
- HTLCHandlingType::NextHopChannel {
5748
+ HTLCHandlingType::ForwardFailed {
5749
5749
node_id: Some(*outgoing_counterparty_node_id),
5750
5750
channel_id: *outgoing_channel_id,
5751
5751
},
@@ -6112,7 +6112,7 @@ where
6112
6112
let data = self.get_htlc_inbound_temp_fail_data(reason);
6113
6113
failed_forwards.push((htlc_source, payment_hash,
6114
6114
HTLCFailReason::reason(reason, data),
6115
- HTLCHandlingType::NextHopChannel { node_id: Some(chan.context.get_counterparty_node_id()), channel_id: forward_chan_id }
6115
+ HTLCHandlingType::ForwardFailed { node_id: Some(chan.context.get_counterparty_node_id()), channel_id: forward_chan_id }
6116
6116
));
6117
6117
} else {
6118
6118
forwarding_channel_not_found!(core::iter::once(forward_info).chain(draining_pending_forwards));
@@ -6968,7 +6968,7 @@ where
6968
6968
6969
6969
for (htlc_src, payment_hash) in htlcs_to_fail.drain(..) {
6970
6970
let reason = HTLCFailReason::reason(failure_reason, onion_failure_data.clone());
6971
- let receiver = HTLCHandlingType::NextHopChannel { node_id: Some(counterparty_node_id.clone()), channel_id };
6971
+ let receiver = HTLCHandlingType::ForwardFailed { node_id: Some(counterparty_node_id.clone()), channel_id };
6972
6972
self.fail_htlc_backwards_internal(&htlc_src, &payment_hash, &reason, receiver);
6973
6973
}
6974
6974
}
@@ -8755,7 +8755,7 @@ This indicates a bug inside LDK. Please report this error at https://github.com/
8755
8755
}
8756
8756
}
8757
8757
for htlc_source in dropped_htlcs.drain(..) {
8758
- let receiver = HTLCHandlingType::NextHopChannel { node_id: Some(counterparty_node_id.clone()), channel_id: msg.channel_id };
8758
+ let receiver = HTLCHandlingType::ForwardFailed { node_id: Some(counterparty_node_id.clone()), channel_id: msg.channel_id };
8759
8759
let reason = HTLCFailReason::from_failure_code(LocalHTLCFailureReason::DroppedPending);
8760
8760
self.fail_htlc_backwards_internal(&htlc_source.0, &htlc_source.1, &reason, receiver);
8761
8761
}
@@ -9613,7 +9613,7 @@ This indicates a bug inside LDK. Please report this error at https://github.com/
9613
9613
} else {
9614
9614
log_trace!(logger, "Failing HTLC with hash {} from our monitor", &htlc_update.payment_hash);
9615
9615
let failure_reason = LocalHTLCFailureReason::ChannelClosed;
9616
- let receiver = HTLCHandlingType::NextHopChannel { node_id: Some(counterparty_node_id), channel_id };
9616
+ let receiver = HTLCHandlingType::ForwardFailed { node_id: Some(counterparty_node_id), channel_id };
9617
9617
let reason = HTLCFailReason::from_failure_code(failure_reason);
9618
9618
self.fail_htlc_backwards_internal(&htlc_update.source, &htlc_update.payment_hash, &reason, receiver);
9619
9619
}
@@ -11692,7 +11692,7 @@ where
11692
11692
let reason = LocalHTLCFailureReason::CLTVExpiryTooSoon;
11693
11693
let data = self.get_htlc_inbound_temp_fail_data(reason);
11694
11694
timed_out_htlcs.push((source, payment_hash, HTLCFailReason::reason(reason, data),
11695
- HTLCHandlingType::NextHopChannel { node_id: Some(funded_channel.context.get_counterparty_node_id()), channel_id: funded_channel.context.channel_id() }));
11695
+ HTLCHandlingType::ForwardFailed { node_id: Some(funded_channel.context.get_counterparty_node_id()), channel_id: funded_channel.context.channel_id() }));
11696
11696
}
11697
11697
let logger = WithChannelContext::from(&self.logger, &funded_channel.context, None);
11698
11698
if let Some(channel_ready) = channel_ready_opt {
@@ -14934,7 +14934,7 @@ where
14934
14934
for htlc_source in failed_htlcs.drain(..) {
14935
14935
let (source, payment_hash, counterparty_node_id, channel_id) = htlc_source;
14936
14936
let failure_reason = LocalHTLCFailureReason::DroppedPending;
14937
- let receiver = HTLCHandlingType::NextHopChannel { node_id: Some(counterparty_node_id), channel_id };
14937
+ let receiver = HTLCHandlingType::ForwardFailed { node_id: Some(counterparty_node_id), channel_id };
14938
14938
let reason = HTLCFailReason::from_failure_code(failure_reason);
14939
14939
channel_manager.fail_htlc_backwards_internal(&source, &payment_hash, &reason, receiver);
14940
14940
}
0 commit comments