Changeset View
Changeset View
Standalone View
Standalone View
src/validation.h
Show First 20 Lines • Show All 1,279 Lines • ▼ Show 20 Lines | public: | ||||
void Unload() EXCLUSIVE_LOCKS_REQUIRED(::cs_main); | void Unload() EXCLUSIVE_LOCKS_REQUIRED(::cs_main); | ||||
//! Clear (deconstruct) chainstate data. | //! Clear (deconstruct) chainstate data. | ||||
void Reset(); | void Reset(); | ||||
//! Check to see if caches are out of balance and if so, call | //! Check to see if caches are out of balance and if so, call | ||||
//! ResizeCoinsCaches() as needed. | //! ResizeCoinsCaches() as needed. | ||||
void MaybeRebalanceCaches() EXCLUSIVE_LOCKS_REQUIRED(::cs_main); | void MaybeRebalanceCaches() EXCLUSIVE_LOCKS_REQUIRED(::cs_main); | ||||
~ChainstateManager() { | |||||
LOCK(::cs_main); | |||||
UnloadBlockIndex(/* mempool */ nullptr, *this); | |||||
Reset(); | |||||
} | |||||
}; | }; | ||||
/** | /** | ||||
* DEPRECATED! Please use node.chainman instead. May only be used in | * DEPRECATED! Please use node.chainman instead. May only be used in | ||||
* validation.cpp internally | * validation.cpp internally | ||||
*/ | */ | ||||
extern ChainstateManager g_chainman GUARDED_BY(::cs_main); | extern ChainstateManager g_chainman GUARDED_BY(::cs_main); | ||||
▲ Show 20 Lines • Show All 43 Lines • Show Last 20 Lines |