Skip to content

Commit d4d1659

Browse files
f fudge expected block times
1 parent 8b74ed4 commit d4d1659

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lightning/src/ln/channelmanager.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10063,7 +10063,8 @@ where
1006310063
let first_hops = self.list_usable_channels();
1006410064
let payee_node_id = self.get_our_node_id();
1006510065

10066-
const SECONDS_PER_BLOCK: u32 = 10 * 60;
10066+
// Assume shorter than usual block times to avoid spuriously failing payments too early.
10067+
const SECONDS_PER_BLOCK: u32 = 9 * 60;
1006710068
let relative_expiry_blocks = relative_expiry_seconds / SECONDS_PER_BLOCK;
1006810069
let max_cltv_expiry = core::cmp::max(relative_expiry_blocks, CLTV_FAR_FAR_AWAY)
1006910070
.saturating_add(LATENCY_GRACE_PERIOD_BLOCKS)

0 commit comments

Comments
 (0)