MCPcopy Create free account
hub / github.com/WaykiChain/WaykiChain / CheckDiskSpace

Function CheckDiskSpace

src/main.cpp:2215–2223  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2213}
2214
2215bool CheckDiskSpace(uint64_t nAdditionalBytes) {
2216 uint64_t nFreeBytesAvailable = filesystem::space(GetDataDir()).available;
2217
2218 // Check for mininum disk space bytes (currently 50MB)
2219 if (nFreeBytesAvailable < MIN_DISK_SPACE + nAdditionalBytes)
2220 return AbortNode(_("Error: Disk space is low!"));
2221
2222 return true;
2223}
2224
2225bool static LoadBlockIndexDB() {
2226 if (!pCdMan->pBlockIndexDb->LoadBlockIndexes())

Callers 4

AppInitFunction · 0.85
FindUndoPosFunction · 0.85
WriteChainStateFunction · 0.85
FindBlockPosFunction · 0.85

Calls 2

AbortNodeFunction · 0.85
_Function · 0.85

Tested by

no test coverage detected