mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-12-05 10:21:20 +01:00
routing: set expiry on initial outgoing HTLC using total time lock
This commit is contained in:
@@ -1002,6 +1002,7 @@ func (r *ChannelRouter) SendPayment(payment *LightningPayment) ([32]byte, *Route
|
|||||||
// payment through the network, starting with the first-hop.
|
// payment through the network, starting with the first-hop.
|
||||||
htlcAdd := &lnwire.UpdateAddHTLC{
|
htlcAdd := &lnwire.UpdateAddHTLC{
|
||||||
Amount: route.TotalAmount,
|
Amount: route.TotalAmount,
|
||||||
|
Expiry: route.TotalTimeLock,
|
||||||
PaymentHash: payment.PaymentHash,
|
PaymentHash: payment.PaymentHash,
|
||||||
}
|
}
|
||||||
copy(htlcAdd.OnionBlob[:], sphinxPacket)
|
copy(htlcAdd.OnionBlob[:], sphinxPacket)
|
||||||
|
|||||||
Reference in New Issue
Block a user