Update dseg limitations
vecMasternodes.size() == 0 is a nearly impossible condition due to the behavior of dseep. Each time a node receives a ping where it's unaware of the masternode it will ask for the dsee from it's peer. - if(c % 5 == 0 && (RequestedMasterNodeList <= 2 || vecMasternodes.size() + if(c % 5 == 0 && RequestedMasterNodeList < 3){
This commit is contained in:
parent
385c532df8
commit
71e074336b
@ -2236,7 +2236,7 @@ void ThreadCheckDarkSendPool()
|
||||
}
|
||||
|
||||
//try to sync the masternode list and payment list every 5 seconds from at least 3 nodes
|
||||
if(c % 5 == 0 && (RequestedMasterNodeList <= 2 || vecMasternodes.size() == 0)){
|
||||
if(c % 5 == 0 && RequestedMasterNodeList < 3){
|
||||
bool fIsInitialDownload = IsInitialBlockDownload();
|
||||
if(!fIsInitialDownload) {
|
||||
LOCK(cs_vNodes);
|
||||
|
@ -273,13 +273,13 @@ void ProcessMessageMasternode(CNode* pfrom, std::string& strCommand, CDataStream
|
||||
{
|
||||
int64_t t = (*i).second;
|
||||
if (GetTime() < t) {
|
||||
Misbehaving(pfrom->GetId(), 20);
|
||||
Misbehaving(pfrom->GetId(), 34);
|
||||
LogPrintf("dseg - peer already asked me for the list\n");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
int64_t askAgain = GetTime()+(60*60*24);
|
||||
int64_t askAgain = GetTime()+(60*60*3);
|
||||
askedForMasternodeList[pfrom->addr] = askAgain;
|
||||
}
|
||||
} //else, asking for a specific node which is ok
|
||||
|
Loading…
Reference in New Issue
Block a user