Skip to content

Commit

Permalink
rpc: Prevent concurrent savemempool
Browse files Browse the repository at this point in the history
  • Loading branch information
promag committed Oct 20, 2018
1 parent 6746a89 commit 585b47c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/validation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4766,6 +4766,9 @@ bool DumpMempool()
std::map<uint256, CAmount> mapDeltas;
std::vector<TxMempoolInfo> vinfo;

static Mutex dump_mutex;
LOCK(dump_mutex);

{
LOCK(mempool.cs);
for (const auto &i : mempool.mapDeltas) {
Expand Down

0 comments on commit 585b47c

Please sign in to comment.