Remove rand throttle
This commit is contained in:
@@ -223,18 +223,13 @@ void komodo_nSPV(CNode *pto)
|
|||||||
if ( (pto->nServices & NODE_ADDRINDEX) != 0 && timestamp > pto->lastutxos + ASSETCHAINS_BLOCKTIME )
|
if ( (pto->nServices & NODE_ADDRINDEX) != 0 && timestamp > pto->lastutxos + ASSETCHAINS_BLOCKTIME )
|
||||||
{
|
{
|
||||||
// get utxo since lastheight
|
// get utxo since lastheight
|
||||||
if ( (rand() % 100) < 10 )
|
|
||||||
{
|
|
||||||
request.resize(1);
|
request.resize(1);
|
||||||
request[0] = NSPV_UTXOS;
|
request[0] = NSPV_UTXOS;
|
||||||
NSPV_lastutxos = pto->lastutxos = timestamp;
|
NSPV_lastutxos = pto->lastutxos = timestamp;
|
||||||
pto->PushMessage("getnSPV",request);
|
pto->PushMessage("getnSPV",request);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if ( timestamp > NSPV_lastinfo + ASSETCHAINS_BLOCKTIME/2 && timestamp > pto->lastinfo + ASSETCHAINS_BLOCKTIME )
|
if ( timestamp > NSPV_lastinfo + ASSETCHAINS_BLOCKTIME/2 && timestamp > pto->lastinfo + ASSETCHAINS_BLOCKTIME )
|
||||||
{
|
|
||||||
if ( (rand() % 100) < 20 )
|
|
||||||
{
|
{
|
||||||
// query current height, blockhash, notarization info
|
// query current height, blockhash, notarization info
|
||||||
request.resize(1);
|
request.resize(1);
|
||||||
@@ -243,6 +238,5 @@ void komodo_nSPV(CNode *pto)
|
|||||||
pto->PushMessage("getnSPV",request);
|
pto->PushMessage("getnSPV",request);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
#endif // KOMODO_NSPV_H
|
#endif // KOMODO_NSPV_H
|
||||||
|
|||||||
Reference in New Issue
Block a user