Skip to content

Commit

Permalink
Bail out from update methods in MasternodeList when shutdown is reque…
Browse files Browse the repository at this point in the history
…sted (#2551)
  • Loading branch information
codablock committed Dec 13, 2018
1 parent 1522656 commit 09730e1
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/qt/masternodelist.cpp
Expand Up @@ -274,6 +274,10 @@ void MasternodeList::updateMyMasternodeInfo(QString strAlias, QString strAddr, c

void MasternodeList::updateMyNodeList(bool fForce)
{
if (ShutdownRequested()) {
return;
}

TRY_LOCK(cs_mymnlist, fLockAcquired);
if (!fLockAcquired) return;

Expand Down Expand Up @@ -310,6 +314,10 @@ void MasternodeList::updateMyNodeList(bool fForce)

void MasternodeList::updateNodeList()
{
if (ShutdownRequested()) {
return;
}

TRY_LOCK(cs_mnlist, fLockAcquired);
if (!fLockAcquired) return;

Expand Down Expand Up @@ -380,6 +388,10 @@ void MasternodeList::updateNodeList()

void MasternodeList::updateDIP3List()
{
if (ShutdownRequested()) {
return;
}

TRY_LOCK(cs_dip3list, fLockAcquired);
if (!fLockAcquired) return;

Expand Down

0 comments on commit 09730e1

Please sign in to comment.