From ef3385192faea327bffd244a087356432d31cd65 Mon Sep 17 00:00:00 2001 From: cryptozoidberg Date: Mon, 29 Jan 2024 15:20:08 +0100 Subject: [PATCH] fixed bug with alt-block coinage validation --- src/currency_core/blockchain_storage.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/currency_core/blockchain_storage.cpp b/src/currency_core/blockchain_storage.cpp index 31cd3a5e..1c85df9f 100644 --- a/src/currency_core/blockchain_storage.cpp +++ b/src/currency_core/blockchain_storage.cpp @@ -7655,7 +7655,7 @@ bool blockchain_storage::validate_alt_block_input(const transaction& input_tx, uint64_t alt_bl_h = split_height + alt_chain.size() + 1; if (m_core_runtime_config.is_hardfork_active_for_height(ZANO_HARDFORK_04_ZARCANUM, alt_bl_h)) { - if (alt_bl_h - max_related_block_height > CURRENCY_HF4_MANDATORY_MIN_COINAGE) + if (alt_bl_h - max_related_block_height < CURRENCY_HF4_MANDATORY_MIN_COINAGE) { LOG_ERROR("Coinage rule broken(altblock): h = " << alt_bl_h << ", max_related_block_height=" << max_related_block_height << ", tx: " << input_tx_hash); return false;