Merge pull request #4076

aa0ea0a blockchain: set the m_verifivation_failed flag in a couple more places (moneromooo-monero)
This commit is contained in:
luigi1111 2018-07-19 14:11:24 -05:00
commit 9474567d76
No known key found for this signature in database
GPG key ID: F4ACA0183641E010

View file

@ -3363,6 +3363,7 @@ bool Blockchain::handle_block_to_main_chain(const block& bl, const crypto::hash&
if(bl.prev_id != get_tail_id())
{
MERROR_VER("Block with id: " << id << std::endl << "has wrong prev_id: " << bl.prev_id << std::endl << "expected: " << get_tail_id());
bvc.m_verifivation_failed = true;
leave:
m_db->block_txn_stop();
return false;
@ -3664,6 +3665,7 @@ leave:
{
//TODO: figure out the best way to deal with this failure
LOG_ERROR("Error adding block with hash: " << id << " to blockchain, what = " << e.what());
bvc.m_verifivation_failed = true;
return_tx_to_pool(txs);
return false;
}