Commit 336cbe29 authored by Bernhard Schuster's avatar Bernhard Schuster
Browse files

fixup: avoid underflow issue

parent 139ecf90
Pipeline #154896 failed with stages
in 9 minutes
......@@ -417,8 +417,8 @@ where
let (lag, subchain_head) = if cfg!(feature = "disputes") {
// Prevent sending flawed data to the dispute-coordinator.
if Some(subchain_block_descriptions.len() as u32 - 1) !=
subchain_number.checked_sub(target_number)
if Some(subchain_block_descriptions.len() as u64) !=
(subchain_number + 1_u64).checked_sub(target_number)
{
tracing::error!(
LOG_TARGET,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment