hardfork: fix accepting v2 blocks too early

This commit is contained in:
moneromooo-monero 2016-01-15 11:34:22 +00:00
parent 10cc6a8593
commit 945ac788d4
No known key found for this signature in database
GPG Key ID: 686F07454D6CEFC3

View File

@ -104,8 +104,7 @@ uint8_t HardFork::get_effective_version(uint8_t voting_version) const
bool HardFork::do_check(uint8_t block_version, uint8_t voting_version) const bool HardFork::do_check(uint8_t block_version, uint8_t voting_version) const
{ {
return block_version >= heights[current_fork_index].version return block_version == heights[current_fork_index].version
&& block_version <= get_ideal_version()
&& voting_version >= heights[current_fork_index].version; && voting_version >= heights[current_fork_index].version;
} }