diff options
| author | Wladimir J. van der Laan <[email protected]> | 2017-05-09 09:29:12 +0200 |
|---|---|---|
| committer | Wladimir J. van der Laan <[email protected]> | 2017-05-09 10:31:45 +0200 |
| commit | c973cc5a43187f4cfd7d053da3f9e35aa3866590 (patch) | |
| tree | 2cb7176f315df1cd6f03e57eb9cf3b599712fb00 /src/bench | |
| parent | Merge #9279: Consensus: Move CFeeRate out of libconsensus (diff) | |
| parent | Chainparams: Use the factory for pow tests (diff) | |
| download | discoin-c973cc5a43187f4cfd7d053da3f9e35aa3866590.tar.xz discoin-c973cc5a43187f4cfd7d053da3f9e35aa3866590.zip | |
Merge #8855: Use a proper factory for creating chainparams
c1082a7 Chainparams: Use the factory for pow tests (Jorge Timón)
2351a06 Chainparams: Get rid of CChainParams& Params(std::string) (Jorge Timón)
f87f362 Chainparams: Use a regular factory for creating chainparams (Jorge Timón)
Tree-SHA512: 359c8a2a1bc9d02db7856d02810240ada28048ac088f878b575597a7255cdb0ffdd1a647085ee67a34c6a7e7ed9e6cfdb61240cf6e75139619b640dbb096072c
Diffstat (limited to 'src/bench')
| -rw-r--r-- | src/bench/checkblock.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bench/checkblock.cpp b/src/bench/checkblock.cpp index c6c932454..195388839 100644 --- a/src/bench/checkblock.cpp +++ b/src/bench/checkblock.cpp @@ -40,7 +40,7 @@ static void DeserializeAndCheckBlockTest(benchmark::State& state) char a = '\0'; stream.write(&a, 1); // Prevent compaction - Consensus::Params params = Params(CBaseChainParams::MAIN).GetConsensus(); + const auto chainParams = CreateChainParams(CBaseChainParams::MAIN); while (state.KeepRunning()) { CBlock block; // Note that CBlock caches its checked state, so we need to recreate it here @@ -48,7 +48,7 @@ static void DeserializeAndCheckBlockTest(benchmark::State& state) assert(stream.Rewind(sizeof(block_bench::block413567))); CValidationState validationState; - assert(CheckBlock(block, validationState, params)); + assert(CheckBlock(block, validationState, chainParams->GetConsensus())); } } |