coins: reset `cachedCoinsUsage` in Flush() only after the map is cleared

Prevents the counter from dropping to 0 while cacheCoins still holds objects
This commit is contained in:
Lőrinc 2025-04-18 11:23:27 +02:00
parent 62c600f79a
commit f1791d64b4
1 changed files with 1 additions and 1 deletions

View File

@ -254,8 +254,8 @@ bool CCoinsViewCache::Flush() {
if (fOk) {
cacheCoins.clear();
ReallocateCache();
}
cachedCoinsUsage = 0;
}
return fOk;
}