From 2e280311b87ac95a765edd3cac05096e48c73545 Mon Sep 17 00:00:00 2001 From: "Wladimir J. van der Laan" Date: Wed, 27 Aug 2014 09:20:33 +0200 Subject: Perform CVerifyDB on pcoinsdbview instead of pcoinsTip Bypassing the main coins cache allows more thorough checking with the same memory budget. This has no effect on performance because everything ends up in the child cache created by VerifyDB itself. It has bugged me ever since #4675, which effectively reduced the number of checked blocks to reduce peak memory usage. - Pass the coinsview to use as argument to VerifyDB - This also avoids that the first `pcoinsTip->Flush()` after VerifyDB writes a large slew of unchanged coin records back to the database. --- src/main.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main.h') diff --git a/src/main.h b/src/main.h index e5357cbfdd..fae8990d20 100644 --- a/src/main.h +++ b/src/main.h @@ -942,7 +942,7 @@ class CVerifyDB { public: CVerifyDB(); ~CVerifyDB(); - bool VerifyDB(int nCheckLevel, int nCheckDepth); + bool VerifyDB(CCoinsView *coinsview, int nCheckLevel, int nCheckDepth); }; /** An in-memory indexed chain of blocks. */ -- cgit v1.2.3