From: bmancini55 Date: Wed, 10 Mar 2021 11:46:44 +0000 (-0500) Subject: Use constant in QueryChannelRange::end_blocknum X-Git-Tag: v0.0.14~48^2~3 X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=commitdiff_plain;h=1809ef199e4c68516b1d4bf1664c63f88d4ef29a;p=rust-lightning Use constant in QueryChannelRange::end_blocknum Clarifies u32 max value used as the default. --- diff --git a/lightning/src/ln/msgs.rs b/lightning/src/ln/msgs.rs index 9fb3a0695..a9c4bc3d6 100644 --- a/lightning/src/ln/msgs.rs +++ b/lightning/src/ln/msgs.rs @@ -1690,7 +1690,7 @@ impl QueryChannelRange { pub fn end_blocknum(&self) -> u32 { match self.first_blocknum.checked_add(self.number_of_blocks) { Some(block) => block, - None => 0xffffffff, + None => u32::max_value(), } } }