From d28ca8ef4102f319450b19d9e5f3cd6effaf44f2 Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Mon, 24 Aug 2015 18:35:34 +0100 Subject: [PATCH] blockchain: make some flag setting code closer to the original code It should not matter in practice, but it makes for simpler double checking when comparing both. --- src/cryptonote_core/blockchain.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cryptonote_core/blockchain.cpp b/src/cryptonote_core/blockchain.cpp index 449ec9591..2c65f70ff 100644 --- a/src/cryptonote_core/blockchain.cpp +++ b/src/cryptonote_core/blockchain.cpp @@ -1279,8 +1279,8 @@ bool Blockchain::handle_alternative_block(const block& b, const crypto::hash& id bool r = switch_to_alternative_blockchain(alt_chain, true); - bvc.m_added_to_main_chain = r; - bvc.m_verifivation_failed = !r; + if (r) bvc.m_added_to_main_chain = true; + else bvc.m_verifivation_failed = true; return r; }