diff options
author | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2016-01-30 22:13:20 +0000 |
---|---|---|
committer | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2016-01-30 22:13:20 +0000 |
commit | 601ad76a5e651638aae1c124eeb286df4db8b347 (patch) | |
tree | a1cf3cdc45b0cd88bd8fc46b2da5d08afe897544 /src/cryptonote_core/hardfork.cpp | |
parent | blockchain: remove unused timer (diff) | |
download | monero-601ad76a5e651638aae1c124eeb286df4db8b347.tar.xz |
hardfork: fix mixup in indexing variable in get_voting_info
Diffstat (limited to 'src/cryptonote_core/hardfork.cpp')
-rw-r--r-- | src/cryptonote_core/hardfork.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cryptonote_core/hardfork.cpp b/src/cryptonote_core/hardfork.cpp index 463d9c065..66fb05010 100644 --- a/src/cryptonote_core/hardfork.cpp +++ b/src/cryptonote_core/hardfork.cpp @@ -373,7 +373,7 @@ bool HardFork::get_voting_info(uint8_t version, uint32_t &window, uint32_t &vote votes = 0; for (size_t n = version; n < 256; ++n) votes += last_versions[n]; - threshold = (window * heights[current_version].threshold + 99) / 100; + threshold = (window * heights[current_fork_index].threshold + 99) / 100; //assert((votes >= threshold) == enabled); earliest_height = get_earliest_ideal_height_for_version(version); voting = heights.back().version; |