Browse Source

Reduce sync frequency for blkindex.dat

Since auto-remove-db-logs was enabled, each time a CTxDB was closed
outside of the initial download window, it causes a checkpoint + log
cleanup. This is overkill, so reduce the sync frequency to once per
minute at most.
pull/1/head
Pieter Wuille 10 years ago
parent
commit
8f2b50f178
  1. 2
      src/db.cpp

2
src/db.cpp

@ -162,6 +162,8 @@ void CDB::Close() @@ -162,6 +162,8 @@ void CDB::Close()
nMinutes = 1;
if (strFile == "addr.dat")
nMinutes = 2;
if (strFile == "blkindex.dat")
nMinutes = 2;
if (strFile == "blkindex.dat" && IsInitialBlockDownload())
nMinutes = 5;

Loading…
Cancel
Save