Skip to content

Commit

Permalink
Fix a crash in masternode winners when count is too large (#2902)
Browse files Browse the repository at this point in the history
  • Loading branch information
UdjinM6 committed May 6, 2019
1 parent 357b727 commit b63f7dd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/masternode-payments.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,10 @@ std::map<int, std::string> GetRequiredPaymentsStrings(int nStartHeight, int nEnd
{
std::map<int, std::string> mapPayments;

if (nStartHeight < 1) {
nStartHeight = 1;
}

LOCK(cs_main);
int nChainTipHeight = chainActive.Height();

Expand Down

0 comments on commit b63f7dd

Please sign in to comment.