Report on-disk size in gettxoutsetinfo

This commit is contained in:
Pieter Wuille
2017-05-12 15:19:19 -07:00
parent d342424301
commit c3aa0c1194
7 changed files with 35 additions and 1 deletions

View File

@@ -67,6 +67,11 @@ bool CCoinsViewDB::BatchWrite(CCoinsMap &mapCoins, const uint256 &hashBlock) {
return db.WriteBatch(batch);
}
size_t CCoinsViewDB::EstimateSize() const
{
return db.EstimateSize(DB_COINS, (char)(DB_COINS+1));
}
CBlockTreeDB::CBlockTreeDB(size_t nCacheSize, bool fMemory, bool fWipe) : CDBWrapper(GetDataDir() / "blocks" / "index", nCacheSize, fMemory, fWipe) {
}