forked from lthn/blockchain
rpc: git rid of obsolete PoS timestamps checks
This commit is contained in:
parent
832b7811b9
commit
69a0117793
2 changed files with 1 additions and 30 deletions
|
|
@ -916,17 +916,6 @@ namespace currency
|
|||
error_resp.message = "Block not accepted";
|
||||
return false;
|
||||
}
|
||||
//@#@
|
||||
//temporary double check timestamp
|
||||
if (time(NULL) - static_cast<int64_t>(get_block_datetime(b)) > 5)
|
||||
{
|
||||
LOG_PRINT_RED_L0("Found block (" << get_block_hash(b) << ") timestamp (" << get_block_datetime(b)
|
||||
<< ") is suspiciously less (" << time(NULL) - static_cast<int64_t>(get_block_datetime(b)) << ") than current time ( " << time(NULL) << ")");
|
||||
//mark node to make it easier to find it via scanner
|
||||
m_core.get_blockchain_storage().get_performnce_data().epic_failure_happend = true;
|
||||
}
|
||||
//
|
||||
|
||||
|
||||
res.status = "OK";
|
||||
return true;
|
||||
|
|
@ -973,17 +962,6 @@ namespace currency
|
|||
error_resp.message = "Block not accepted";
|
||||
return false;
|
||||
}
|
||||
//@#@
|
||||
//temporary double check timestamp
|
||||
if (time(NULL) - static_cast<int64_t>(get_block_datetime(b)) > 5)
|
||||
{
|
||||
LOG_PRINT_RED_L0("Found block (" << get_block_hash(b) << ") timestamp (" << get_block_datetime(b)
|
||||
<< ") is suspiciously less (" << time(NULL) - static_cast<int64_t>(get_block_datetime(b)) << ") than current time ( " << time(NULL) << ")");
|
||||
//mark node to make it easier to find it via scanner
|
||||
m_core.get_blockchain_storage().get_performnce_data().epic_failure_happend = true;
|
||||
}
|
||||
//
|
||||
|
||||
|
||||
res.status = "OK";
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -3560,14 +3560,7 @@ bool wallet2::build_minted_block(const currency::COMMAND_RPC_SCAN_POS::request&
|
|||
}
|
||||
WLT_LOG_GREEN("POS block generated and accepted, congrats!", LOG_LEVEL_0);
|
||||
m_wcallback->on_pos_block_found(b);
|
||||
//@#@
|
||||
//double check timestamp
|
||||
if (time(NULL) - static_cast<int64_t>(get_block_datetime(b)) > 5)
|
||||
{
|
||||
WLT_LOG_RED("Found block (" << get_block_hash(b) << ") timestamp (" << get_block_datetime(b)
|
||||
<< ") is suspiciously less (" << time(NULL) - static_cast<int64_t>(get_block_datetime(b)) << ") than current time ( " << time(NULL) << ")", LOG_LEVEL_0);
|
||||
}
|
||||
//
|
||||
|
||||
return true;
|
||||
}
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue