protocol: only print sync complete message when out of precompiled hashes

This avoids most premature triggers
This commit is contained in:
moneromooo-monero 2019-09-24 15:27:50 +00:00
parent 2c171a9b02
commit 74a23e9a59
No known key found for this signature in database
GPG key ID: 686F07454D6CEFC3

View file

@ -2064,7 +2064,7 @@ skip:
bool t_cryptonote_protocol_handler<t_core>::on_connection_synchronized()
{
bool val_expected = false;
if(m_synchronized.compare_exchange_strong(val_expected, true))
if(!m_core.is_within_compiled_block_hash_area(m_core.get_current_blockchain_height()) && m_synchronized.compare_exchange_strong(val_expected, true))
{
MGINFO_YELLOW(ENDL << "**********************************************************************" << ENDL
<< "You are now synchronized with the network. You may now start monero-wallet-cli." << ENDL