diff options
author | Pieter Wuille <pieter.wuille@gmail.com> | 2013-02-16 17:58:45 +0100 |
---|---|---|
committer | Pieter Wuille <pieter.wuille@gmail.com> | 2013-02-17 23:25:42 +0100 |
commit | f7f3a96b74bb795d6e184a628adce21c744d234f (patch) | |
tree | 79999de8be9721005662fc0dcc51cc4a030a1256 /src/main.cpp | |
parent | 2f0fa79db290d5139c27409055b2035099afa6fd (diff) |
Improve block database load error reporting
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp index 8c115c26f9..3151a806dc 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -2653,6 +2653,18 @@ bool VerifyDB() { return true; } +void UnloadBlockIndex() +{ + mapBlockIndex.clear(); + setBlockIndexValid.clear(); + pindexGenesisBlock = NULL; + nBestHeight = 0; + bnBestChainWork = 0; + bnBestInvalidWork = 0; + hashBestChain = 0; + pindexBest = NULL; +} + bool LoadBlockIndex() { if (fTestNet) |