Set fValid=true when receiving new votes

This commit is contained in:
Evan Duffield 2015-07-17 07:40:26 -07:00
parent d60f3f6984
commit b6001065ae

View File

@ -772,6 +772,7 @@ void CBudgetManager::ProcessMessage(CNode* pfrom, std::string& strCommand, CData
if (strCommand == "mvote") { //Masternode Vote if (strCommand == "mvote") { //Masternode Vote
CBudgetVote vote; CBudgetVote vote;
vRecv >> vote; vRecv >> vote;
vote.fValid = true;
if(mapSeenMasternodeBudgetVotes.count(vote.GetHash())){ if(mapSeenMasternodeBudgetVotes.count(vote.GetHash())){
return; return;
@ -835,6 +836,7 @@ void CBudgetManager::ProcessMessage(CNode* pfrom, std::string& strCommand, CData
if (strCommand == "fbvote") { //Finalized Budget Vote if (strCommand == "fbvote") { //Finalized Budget Vote
CFinalizedBudgetVote vote; CFinalizedBudgetVote vote;
vRecv >> vote; vRecv >> vote;
vote.fValid = true;
if(mapSeenFinalizedBudgetVotes.count(vote.GetHash())){ if(mapSeenFinalizedBudgetVotes.count(vote.GetHash())){
return; return;