mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-03-23 14:10:15 +01:00
Return void instead of bool for functions that cannot fail
* CBlockTreeDB::ReadReindexing(...) * CChainState::ResetBlockFailureFlags(...) * CTxMemPool::addUnchecked(...) * CWallet::LoadDestData(...) * CWallet::LoadKeyMetadata(...) * CWallet::LoadScriptMetadata(...) * CWallet::LoadToWallet(...) * CWallet::SetHDChain(...) * CWallet::SetHDSeed(...) * RemoveLocal(...) * SetMinVersion(...) * StartHTTPServer(...) * StartRPC(...) * TorControlConnection::Disconnect(...)
This commit is contained in:
@@ -178,7 +178,7 @@ public:
|
||||
// Manual block validity manipulation:
|
||||
bool PreciousBlock(CValidationState& state, const CChainParams& params, CBlockIndex* pindex) LOCKS_EXCLUDED(cs_main);
|
||||
bool InvalidateBlock(CValidationState& state, const CChainParams& chainparams, CBlockIndex* pindex) EXCLUSIVE_LOCKS_REQUIRED(cs_main);
|
||||
bool ResetBlockFailureFlags(CBlockIndex* pindex) EXCLUSIVE_LOCKS_REQUIRED(cs_main);
|
||||
void ResetBlockFailureFlags(CBlockIndex* pindex) EXCLUSIVE_LOCKS_REQUIRED(cs_main);
|
||||
|
||||
bool ReplayBlocks(const CChainParams& params, CCoinsView* view);
|
||||
bool RewindBlockIndex(const CChainParams& params);
|
||||
@@ -2882,7 +2882,7 @@ bool InvalidateBlock(CValidationState& state, const CChainParams& chainparams, C
|
||||
return g_chainstate.InvalidateBlock(state, chainparams, pindex);
|
||||
}
|
||||
|
||||
bool CChainState::ResetBlockFailureFlags(CBlockIndex *pindex) {
|
||||
void CChainState::ResetBlockFailureFlags(CBlockIndex *pindex) {
|
||||
AssertLockHeld(cs_main);
|
||||
|
||||
int nHeight = pindex->nHeight;
|
||||
@@ -2914,9 +2914,9 @@ bool CChainState::ResetBlockFailureFlags(CBlockIndex *pindex) {
|
||||
}
|
||||
pindex = pindex->pprev;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
bool ResetBlockFailureFlags(CBlockIndex *pindex) {
|
||||
|
||||
void ResetBlockFailureFlags(CBlockIndex *pindex) {
|
||||
return g_chainstate.ResetBlockFailureFlags(pindex);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user