rpc: Prevent concurrent savemempool
This commit is contained in:
parent
6746a89519
commit
585b47cfe1
1 changed files with 3 additions and 0 deletions
|
@ -4766,6 +4766,9 @@ bool DumpMempool()
|
||||||
std::map<uint256, CAmount> mapDeltas;
|
std::map<uint256, CAmount> mapDeltas;
|
||||||
std::vector<TxMempoolInfo> vinfo;
|
std::vector<TxMempoolInfo> vinfo;
|
||||||
|
|
||||||
|
static Mutex dump_mutex;
|
||||||
|
LOCK(dump_mutex);
|
||||||
|
|
||||||
{
|
{
|
||||||
LOCK(mempool.cs);
|
LOCK(mempool.cs);
|
||||||
for (const auto &i : mempool.mapDeltas) {
|
for (const auto &i : mempool.mapDeltas) {
|
||||||
|
|
Loading…
Reference in a new issue