From d7c6458ca76f9431f0728a86f30685f7aab70f22 Mon Sep 17 00:00:00 2001 From: Kevin Heifner Date: Thu, 18 Jan 2024 07:58:26 -0600 Subject: [PATCH] GH-2100 Use core.last_final_block_num for if irreversible_blocknum() --- libraries/chain/include/eosio/chain/block_state.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/chain/include/eosio/chain/block_state.hpp b/libraries/chain/include/eosio/chain/block_state.hpp index 844b3b9b35..a95fc61a7a 100644 --- a/libraries/chain/include/eosio/chain/block_state.hpp +++ b/libraries/chain/include/eosio/chain/block_state.hpp @@ -30,7 +30,7 @@ struct block_state : public block_header_state { // block_header_state provi const extensions_type& header_extensions() const { return block_header_state::header.header_extensions; } bool is_valid() const { return validated; } void set_valid(bool b) { validated = b; } - uint32_t irreversible_blocknum() const { return 0; } // [greg todo] equivalent of dpos_irreversible_blocknum + uint32_t irreversible_blocknum() const { return core.last_final_block_num; } std::optional get_best_qc() const; protocol_feature_activation_set_ptr get_activated_protocol_features() const { return block_header_state::activated_protocol_features; }