mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-26 14:00:29 +01:00
walletdb: Move PeriodicFlush into WalletDatabase
Make PeriodicFlush a non-static member of WalletDatabase instead of WalletBatch.
This commit is contained in:
@@ -614,14 +614,12 @@ void BerkeleyEnvironment::Flush(bool fShutdown)
|
||||
}
|
||||
}
|
||||
|
||||
bool BerkeleyBatch::PeriodicFlush(BerkeleyDatabase& database)
|
||||
bool BerkeleyDatabase::PeriodicFlush()
|
||||
{
|
||||
if (database.IsDummy()) {
|
||||
if (IsDummy()) {
|
||||
return true;
|
||||
}
|
||||
bool ret = false;
|
||||
BerkeleyEnvironment *env = database.env.get();
|
||||
const std::string& strFile = database.strFile;
|
||||
TRY_LOCK(cs_db, lockDb);
|
||||
if (lockDb)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user