From 5d91b26c0f8ab95aba984c97b8aed093601de8e7 Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Sun, 30 Jul 2017 09:45:55 +0100 Subject: blockchain: skip checking tx semantics in embedded block hash range If the txes are bad, this'll be picked up by the block hash mismatch since the tx merkle root is part of the block hash. --- src/cryptonote_core/blockchain.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/cryptonote_core/blockchain.cpp') diff --git a/src/cryptonote_core/blockchain.cpp b/src/cryptonote_core/blockchain.cpp index 745608b9f..6c4bb4e07 100644 --- a/src/cryptonote_core/blockchain.cpp +++ b/src/cryptonote_core/blockchain.cpp @@ -4154,6 +4154,15 @@ void Blockchain::load_compiled_in_block_hashes() } #endif +bool Blockchain::is_within_compiled_block_hash_area(uint64_t height) const +{ +#if defined(PER_BLOCK_CHECKPOINT) + return height < m_blocks_hash_check.size(); +#else + return false; +#endif +} + void Blockchain::lock() { m_blockchain_lock.lock(); -- cgit v1.2.3