From ea92a32f725c3f8c82bda6002bff3c7f9ae3e65b Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Wed, 11 Sep 2019 01:04:01 +0000 Subject: [PATCH 1/2] Revert "Fix check for disconnecting peers when syncing" This reverts commit adc16d2504d3e76b0115791caf10446684d45433. --- src/cryptonote_protocol/cryptonote_protocol_handler.inl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cryptonote_protocol/cryptonote_protocol_handler.inl b/src/cryptonote_protocol/cryptonote_protocol_handler.inl index 65115ee72..e050dda05 100644 --- a/src/cryptonote_protocol/cryptonote_protocol_handler.inl +++ b/src/cryptonote_protocol/cryptonote_protocol_handler.inl @@ -342,7 +342,7 @@ namespace cryptonote if(m_core.have_block(hshd.top_id)) { - if (target > m_core.get_current_blockchain_height()) + if (target > hshd.current_height) { MINFO(context << "peer is not ahead of us and we're syncing, disconnecting"); return false; From 62fc4bec4c92f1b509304c545f6e8c810e56c0c7 Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Wed, 11 Sep 2019 01:04:44 +0000 Subject: [PATCH 2/2] Revert "cryptonote_protocol: drop peers we can't download from when syncing" This reverts commit a96c1a46d4b3854252de75cbe09458ad5d1aecb0. --- src/cryptonote_protocol/cryptonote_protocol_handler.inl | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/cryptonote_protocol/cryptonote_protocol_handler.inl b/src/cryptonote_protocol/cryptonote_protocol_handler.inl index e050dda05..9f01a7320 100644 --- a/src/cryptonote_protocol/cryptonote_protocol_handler.inl +++ b/src/cryptonote_protocol/cryptonote_protocol_handler.inl @@ -342,11 +342,6 @@ namespace cryptonote if(m_core.have_block(hshd.top_id)) { - if (target > hshd.current_height) - { - MINFO(context << "peer is not ahead of us and we're syncing, disconnecting"); - return false; - } context.m_state = cryptonote_connection_context::state_normal; if(is_inital && target == m_core.get_current_blockchain_height()) on_connection_synchronized();