Skip to content

Commit

Permalink
Use VersionBitsState instead of VersionBitsTipState to avoid cs_main …
Browse files Browse the repository at this point in the history
…lock (#2370)

It wasn't even locked, which causes AssertLockHeld to fail.
  • Loading branch information
codablock authored Oct 24, 2018
1 parent c4351fd commit 3c9237a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/dsnotificationinterface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ void CDSNotificationInterface::UpdatedBlockTip(const CBlockIndex *pindexNew, con
fDIP0003ActiveAtTip = (VersionBitsState(pindexNew->pprev, Params().GetConsensus(), Consensus::DEPLOYMENT_DIP0003, versionbitscache) == THRESHOLD_ACTIVE);
// update instantsend autolock activation flag
instantsend.isAutoLockBip9Active =
(VersionBitsTipState(Params().GetConsensus(), Consensus::DEPLOYMENT_ISAUTOLOCKS) == THRESHOLD_ACTIVE);
(VersionBitsState(pindexNew->pprev, Params().GetConsensus(), Consensus::DEPLOYMENT_ISAUTOLOCKS, versionbitscache) == THRESHOLD_ACTIVE);

if (fInitialDownload)
return;
Expand Down

0 comments on commit 3c9237a

Please sign in to comment.