diff options
author | MarcoFalke <falke.marco@gmail.com> | 2018-12-17 14:27:43 -0500 |
---|---|---|
committer | MarcoFalke <falke.marco@gmail.com> | 2018-12-17 14:27:29 -0500 |
commit | fafe941bdd4572b5b9200457a2267888d7efd9bb (patch) | |
tree | 77e48cd8829ce5c27e0aa0ff1321a59ae5af10cc /src/bench/mempool_eviction.cpp | |
parent | fac4558462cb668581c1a6564876f58093901b9c (diff) |
test: Add missing validation locks
Diffstat (limited to 'src/bench/mempool_eviction.cpp')
-rw-r--r-- | src/bench/mempool_eviction.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bench/mempool_eviction.cpp b/src/bench/mempool_eviction.cpp index 49ea6e88b5..ac8a182358 100644 --- a/src/bench/mempool_eviction.cpp +++ b/src/bench/mempool_eviction.cpp @@ -9,7 +9,7 @@ #include <list> #include <vector> -static void AddTx(const CTransactionRef& tx, const CAmount& nFee, CTxMemPool& pool) EXCLUSIVE_LOCKS_REQUIRED(pool.cs) +static void AddTx(const CTransactionRef& tx, const CAmount& nFee, CTxMemPool& pool) EXCLUSIVE_LOCKS_REQUIRED(cs_main, pool.cs) { int64_t nTime = 0; unsigned int nHeight = 1; @@ -108,7 +108,7 @@ static void MempoolEviction(benchmark::State& state) tx7.vout[1].nValue = 10 * COIN; CTxMemPool pool; - LOCK(pool.cs); + LOCK2(cs_main, pool.cs); // Create transaction references outside the "hot loop" const CTransactionRef tx1_r{MakeTransactionRef(tx1)}; const CTransactionRef tx2_r{MakeTransactionRef(tx2)}; |