diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2015-11-12 17:37:42 +0100 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2015-11-12 17:37:52 +0100 |
commit | eb6172a8ca7e0474457c1206c9907514348243ea (patch) | |
tree | a1c38ef1b59210deb1c2d60ebe0d13869f48efe6 /src/main.cpp | |
parent | 54e8bfec8387ee154f8b15b41ae0b29bc2cd9bbc (diff) | |
parent | 69d373ff6693de204bdf58cbc90f8a26d8f711c8 (diff) | |
download | bitcoin-eb6172a8ca7e0474457c1206c9907514348243ea.tar.xz |
Merge pull request #6918
69d373f Don't wipe the sigcache in TestBlockValidity (Pieter Wuille)
0b9e9dc Evict sigcache entries that are seen in a block (Pieter Wuille)
830e3f3 Make sigcache faster and more efficient (Pieter Wuille)
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main.cpp b/src/main.cpp index 6e5a81f306..3703701917 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1851,7 +1851,8 @@ bool ConnectBlock(const CBlock& block, CValidationState& state, CBlockIndex* pin nFees += view.GetValueIn(tx)-tx.GetValueOut(); std::vector<CScriptCheck> vChecks; - if (!CheckInputs(tx, state, view, fScriptChecks, flags, false, nScriptCheckThreads ? &vChecks : NULL)) + bool fCacheResults = fJustCheck; /* Don't cache results if we're actually connecting blocks (still consult the cache, though) */ + if (!CheckInputs(tx, state, view, fScriptChecks, flags, fCacheResults, nScriptCheckThreads ? &vChecks : NULL)) return error("ConnectBlock(): CheckInputs on %s failed with %s", tx.GetHash().ToString(), FormatStateMessage(state)); control.Add(vChecks); |