aboutsummaryrefslogtreecommitdiff
path: root/src/cryptonote_protocol
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2018-01-25 16:39:16 -0800
committerRiccardo Spagni <ric@spagni.net>2018-01-25 16:39:16 -0800
commit75cbb7719e519c10fd05ed64df2aab9befe756ba (patch)
treee2141035ad4650afdaf37b8aefa7cafffe3bc2fc /src/cryptonote_protocol
parentMerge pull request #3014 (diff)
parentcryptonote_protocol: update target height when receiving blocks (diff)
downloadmonero-75cbb7719e519c10fd05ed64df2aab9befe756ba.tar.xz
Merge pull request #3015
f06603a4 cryptonote_protocol: update target height when receiving blocks (moneromooo-monero)
Diffstat (limited to 'src/cryptonote_protocol')
-rw-r--r--src/cryptonote_protocol/cryptonote_protocol_handler.inl2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/cryptonote_protocol/cryptonote_protocol_handler.inl b/src/cryptonote_protocol/cryptonote_protocol_handler.inl
index 5d25d1058..6c350775d 100644
--- a/src/cryptonote_protocol/cryptonote_protocol_handler.inl
+++ b/src/cryptonote_protocol/cryptonote_protocol_handler.inl
@@ -876,6 +876,8 @@ namespace cryptonote
}
context.m_remote_blockchain_height = arg.current_blockchain_height;
+ if (context.m_remote_blockchain_height > m_core.get_target_blockchain_height())
+ m_core.set_target_blockchain_height(context.m_remote_blockchain_height);
std::vector<crypto::hash> block_hashes;
block_hashes.reserve(arg.blocks.size());