X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;ds=sidebyside;f=lightning%2Fsrc%2Fln%2Foutbound_payment.rs;fp=lightning%2Fsrc%2Fln%2Foutbound_payment.rs;h=546dc6c5bcd93171411263ff1c77229a08ea2ae1;hb=ab80fcf953c95eae488f5ba1ed03fc31d335d547;hp=2ac24baa58b3466315c2628c711f17e4f3d17d73;hpb=bd1206777735696c7aa5ece2f2f2bda6c5a87661;p=rust-lightning diff --git a/lightning/src/ln/outbound_payment.rs b/lightning/src/ln/outbound_payment.rs index 2ac24baa..546dc6c5 100644 --- a/lightning/src/ln/outbound_payment.rs +++ b/lightning/src/ln/outbound_payment.rs @@ -239,7 +239,7 @@ impl Retry { }, #[cfg(all(not(feature = "no-std"), not(test)))] (Retry::Timeout(max_duration), PaymentAttempts { first_attempted_at, .. }) => - *max_duration >= std::time::Instant::now().duration_since(*first_attempted_at), + *max_duration >= crate::util::time::MonotonicTime::now().duration_since(*first_attempted_at), #[cfg(all(not(feature = "no-std"), test))] (Retry::Timeout(max_duration), PaymentAttempts { first_attempted_at, .. }) => *max_duration >= SinceEpoch::now().duration_since(*first_attempted_at), @@ -274,7 +274,7 @@ pub(crate) struct PaymentAttemptsUsingTime { } #[cfg(not(any(feature = "no-std", test)))] -type ConfiguredTime = std::time::Instant; +type ConfiguredTime = crate::util::time::MonotonicTime; #[cfg(feature = "no-std")] type ConfiguredTime = crate::util::time::Eternity; #[cfg(all(not(feature = "no-std"), test))]