diff options
author | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2020-06-05 15:26:39 +0000 |
---|---|---|
committer | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2020-06-05 15:27:07 +0000 |
commit | 795e18632c0bbc0557393d321fe016f09861c309 (patch) | |
tree | f7a0d4bce8a7039538535d688ff5879aa3febf09 /src/cryptonote_core/blockchain.cpp | |
parent | Merge pull request #6612 (diff) | |
download | monero-795e18632c0bbc0557393d321fe016f09861c309.tar.xz |
blockchain: fix total_height in getblocks.bin response
Diffstat (limited to 'src/cryptonote_core/blockchain.cpp')
-rw-r--r-- | src/cryptonote_core/blockchain.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/cryptonote_core/blockchain.cpp b/src/cryptonote_core/blockchain.cpp index 2571e4203..dda378202 100644 --- a/src/cryptonote_core/blockchain.cpp +++ b/src/cryptonote_core/blockchain.cpp @@ -2493,6 +2493,7 @@ bool Blockchain::find_blockchain_supplement(const uint64_t req_start_block, cons } db_rtxn_guard rtxn_guard(m_db); + total_height = get_current_blockchain_height(); blocks.reserve(std::min(std::min(max_count, (size_t)10000), (size_t)(total_height - start_height))); CHECK_AND_ASSERT_MES(m_db->get_blocks_from(start_height, 3, max_count, FIND_BLOCKCHAIN_SUPPLEMENT_MAX_SIZE, blocks, pruned, true, get_miner_tx_hash), false, "Error getting blocks"); |