mirror of
https://github.com/dashpay/dash.git
synced 2024-12-25 12:02:48 +01:00
Filter SigTime modes / version / proto bump
This commit is contained in:
parent
50121bbf69
commit
61745d7724
@ -3,7 +3,7 @@ AC_PREREQ([2.60])
|
||||
define(_CLIENT_VERSION_MAJOR, 0)
|
||||
define(_CLIENT_VERSION_MINOR, 12)
|
||||
define(_CLIENT_VERSION_REVISION, 0)
|
||||
define(_CLIENT_VERSION_BUILD, 27)
|
||||
define(_CLIENT_VERSION_BUILD, 28)
|
||||
define(_CLIENT_VERSION_IS_RELEASE, true)
|
||||
define(_COPYRIGHT_YEAR, 2015)
|
||||
AC_INIT([Dash Core],[_CLIENT_VERSION_MAJOR._CLIENT_VERSION_MINOR._CLIENT_VERSION_REVISION],[info@dashpay.io],[dash])
|
||||
|
@ -17,7 +17,7 @@
|
||||
#define CLIENT_VERSION_MAJOR 0
|
||||
#define CLIENT_VERSION_MINOR 12
|
||||
#define CLIENT_VERSION_REVISION 0
|
||||
#define CLIENT_VERSION_BUILD 27
|
||||
#define CLIENT_VERSION_BUILD 28
|
||||
|
||||
//! Set to true for release, false for prerelease or test build
|
||||
#define CLIENT_VERSION_IS_RELEASE true
|
||||
|
@ -27,7 +27,7 @@ class CConsensusVote;
|
||||
class CTransaction;
|
||||
class CTransactionLock;
|
||||
|
||||
static const int MIN_INSTANTX_PROTO_VERSION = 70095;
|
||||
static const int MIN_INSTANTX_PROTO_VERSION = 70096;
|
||||
|
||||
extern map<uint256, CTransaction> mapTxLockReq;
|
||||
extern map<uint256, CTransaction> mapTxLockReqRejected;
|
||||
|
@ -672,7 +672,9 @@ bool CMasternodePayments::ProcessBlock(int nBlockHeight)
|
||||
LogPrintf("CMasternodePayments::ProcessBlock() Start nHeight %d - vin %s. \n", nBlockHeight, activeMasternode.vin.ToString().c_str());
|
||||
|
||||
// pay to the oldest MN that still had no payment but its input is old enough and it was active long enough
|
||||
CMasternode *pmn = mnodeman.GetNextMasternodeInQueueForPayment(nBlockHeight);
|
||||
CMasternode *pmn = mnodeman.GetNextMasternodeInQueueForPayment(nBlockHeight, true);
|
||||
if(pmn == NULL) pmn = mnodeman.GetNextMasternodeInQueueForPayment(nBlockHeight, false); // if no results, look for any node with a newer sigTime
|
||||
|
||||
if(pmn != NULL)
|
||||
{
|
||||
LogPrintf("CMasternodePayments::ProcessBlock() Found by FindOldestNotInVec \n");
|
||||
|
@ -388,7 +388,7 @@ CMasternode *CMasternodeMan::Find(const CPubKey &pubKeyMasternode)
|
||||
//
|
||||
// Deterministically select the oldest/best masternode to pay on the network
|
||||
//
|
||||
CMasternode* CMasternodeMan::GetNextMasternodeInQueueForPayment(int nBlockHeight)
|
||||
CMasternode* CMasternodeMan::GetNextMasternodeInQueueForPayment(int nBlockHeight, bool fFilterSigTime)
|
||||
{
|
||||
LOCK(cs);
|
||||
|
||||
@ -412,7 +412,7 @@ CMasternode* CMasternodeMan::GetNextMasternodeInQueueForPayment(int nBlockHeight
|
||||
if(masternodePayments.IsScheduled(mn, nBlockHeight)) continue;
|
||||
|
||||
//it's too new, wait for a cycle
|
||||
if(mn.sigTime + (nMnCount*2.6*60) > GetAdjustedTime()) continue;
|
||||
if(fFilterSigTime && mn.sigTime + (nMnCount*2.6*60) > GetAdjustedTime()) continue;
|
||||
|
||||
//make sure it has as many confirmations as there are masternodes
|
||||
if(mn.GetMasternodeInputAge() < nMnCount) continue;
|
||||
|
@ -111,7 +111,7 @@ public:
|
||||
CMasternode* Find(const CPubKey& pubKeyMasternode);
|
||||
|
||||
/// Find an entry in the masternode list that is next to be paid
|
||||
CMasternode* GetNextMasternodeInQueueForPayment(int nBlockHeight);
|
||||
CMasternode* GetNextMasternodeInQueueForPayment(int nBlockHeight, bool fFilterSigTime=true);
|
||||
|
||||
/// Find a random entry
|
||||
CMasternode* FindRandom();
|
||||
|
@ -10,7 +10,7 @@
|
||||
* network protocol versioning
|
||||
*/
|
||||
|
||||
static const int PROTOCOL_VERSION = 70095;
|
||||
static const int PROTOCOL_VERSION = 70096;
|
||||
|
||||
//! initial proto version, to be increased after version/verack negotiation
|
||||
static const int INIT_PROTO_VERSION = 209;
|
||||
@ -22,19 +22,19 @@ static const int GETHEADERS_VERSION = 70077;
|
||||
static const int MIN_PEER_PROTO_VERSION = 70066;
|
||||
|
||||
//! minimum peer version accepted by DarksendPool
|
||||
static const int MIN_POOL_PEER_PROTO_VERSION = 70095;
|
||||
static const int MIN_POOL_PEER_PROTO_VERSION = 70096;
|
||||
|
||||
//! minimum peer version for masternode budgets
|
||||
static const int MIN_BUDGET_PEER_PROTO_VERSION = 70095;
|
||||
static const int MIN_BUDGET_PEER_PROTO_VERSION = 70096;
|
||||
|
||||
//! minimum peer version for masternode winner broadcasts
|
||||
static const int MIN_MNW_PEER_PROTO_VERSION = 70095;
|
||||
static const int MIN_MNW_PEER_PROTO_VERSION = 70096;
|
||||
|
||||
//! minimum peer version that can receive masternode payments
|
||||
// V1 - Last protocol version before update
|
||||
// V2 - Newest protocol version
|
||||
static const int MIN_MASTERNODE_PAYMENT_PROTO_VERSION_1 = 70066;
|
||||
static const int MIN_MASTERNODE_PAYMENT_PROTO_VERSION_2 = 70095;
|
||||
static const int MIN_MASTERNODE_PAYMENT_PROTO_VERSION_2 = 70096;
|
||||
|
||||
//! nTime field added to CAddress, starting with this version;
|
||||
//! if possible, avoid requesting addresses nodes older than this
|
||||
|
Loading…
Reference in New Issue
Block a user