Merge branch 'v0.12.0.x'
This commit is contained in:
commit
11a015664b
@ -3,7 +3,7 @@ AC_PREREQ([2.60])
|
|||||||
define(_CLIENT_VERSION_MAJOR, 0)
|
define(_CLIENT_VERSION_MAJOR, 0)
|
||||||
define(_CLIENT_VERSION_MINOR, 12)
|
define(_CLIENT_VERSION_MINOR, 12)
|
||||||
define(_CLIENT_VERSION_REVISION, 0)
|
define(_CLIENT_VERSION_REVISION, 0)
|
||||||
define(_CLIENT_VERSION_BUILD, 47)
|
define(_CLIENT_VERSION_BUILD, 48)
|
||||||
define(_CLIENT_VERSION_IS_RELEASE, true)
|
define(_CLIENT_VERSION_IS_RELEASE, true)
|
||||||
define(_COPYRIGHT_YEAR, 2015)
|
define(_COPYRIGHT_YEAR, 2015)
|
||||||
AC_INIT([Dash Core],[_CLIENT_VERSION_MAJOR._CLIENT_VERSION_MINOR._CLIENT_VERSION_REVISION],[info@dashpay.io],[dash])
|
AC_INIT([Dash Core],[_CLIENT_VERSION_MAJOR._CLIENT_VERSION_MINOR._CLIENT_VERSION_REVISION],[info@dashpay.io],[dash])
|
||||||
|
@ -42,6 +42,18 @@ void CActiveMasternode::ManageStatus()
|
|||||||
status = ACTIVE_MASTERNODE_NOT_CAPABLE;
|
status = ACTIVE_MASTERNODE_NOT_CAPABLE;
|
||||||
notCapableReason = "";
|
notCapableReason = "";
|
||||||
|
|
||||||
|
if(pwalletMain->IsLocked()){
|
||||||
|
notCapableReason = "Wallet is locked.";
|
||||||
|
LogPrintf("CActiveMasternode::ManageStatus() - not capable: %s\n", notCapableReason);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(pwalletMain->GetBalance() == 0){
|
||||||
|
notCapableReason = "Hot node, waiting for remote activation.";
|
||||||
|
LogPrintf("CActiveMasternode::ManageStatus() - not capable: %s\n", notCapableReason);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if(strMasterNodeAddr.empty()) {
|
if(strMasterNodeAddr.empty()) {
|
||||||
if(!GetLocal(service)) {
|
if(!GetLocal(service)) {
|
||||||
notCapableReason = "Can't detect external address. Please use the masternodeaddr configuration option.";
|
notCapableReason = "Can't detect external address. Please use the masternodeaddr configuration option.";
|
||||||
@ -72,13 +84,6 @@ void CActiveMasternode::ManageStatus()
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(pwalletMain->IsLocked()){
|
|
||||||
notCapableReason = "Wallet is locked.";
|
|
||||||
LogPrintf("CActiveMasternode::ManageStatus() - not capable: %s\n", notCapableReason);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// Choose coins to use
|
// Choose coins to use
|
||||||
CPubKey pubKeyCollateralAddress;
|
CPubKey pubKeyCollateralAddress;
|
||||||
CKey keyCollateralAddress;
|
CKey keyCollateralAddress;
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
#define CLIENT_VERSION_MAJOR 0
|
#define CLIENT_VERSION_MAJOR 0
|
||||||
#define CLIENT_VERSION_MINOR 12
|
#define CLIENT_VERSION_MINOR 12
|
||||||
#define CLIENT_VERSION_REVISION 0
|
#define CLIENT_VERSION_REVISION 0
|
||||||
#define CLIENT_VERSION_BUILD 47
|
#define CLIENT_VERSION_BUILD 48
|
||||||
|
|
||||||
//! Set to true for release, false for prerelease or test build
|
//! Set to true for release, false for prerelease or test build
|
||||||
#define CLIENT_VERSION_IS_RELEASE true
|
#define CLIENT_VERSION_IS_RELEASE true
|
||||||
|
@ -1525,12 +1525,15 @@ bool CDarksendPool::DoAutomaticDenominating(bool fDryRun)
|
|||||||
//non-denom's are incompatible
|
//non-denom's are incompatible
|
||||||
if((dsq.nDenom & (1 << 4))) continue;
|
if((dsq.nDenom & (1 << 4))) continue;
|
||||||
|
|
||||||
|
bool fUsed = false;
|
||||||
//don't reuse Masternodes
|
//don't reuse Masternodes
|
||||||
BOOST_FOREACH(CTxIn usedVin, vecMasternodesUsed){
|
BOOST_FOREACH(CTxIn usedVin, vecMasternodesUsed){
|
||||||
if(dsq.vin == usedVin) {
|
if(dsq.vin == usedVin) {
|
||||||
continue;
|
fUsed = true;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if(fUsed) continue;
|
||||||
|
|
||||||
std::vector<CTxIn> vTempCoins;
|
std::vector<CTxIn> vTempCoins;
|
||||||
std::vector<COutput> vTempCoins2;
|
std::vector<COutput> vTempCoins2;
|
||||||
@ -1563,7 +1566,7 @@ bool CDarksendPool::DoAutomaticDenominating(bool fDryRun)
|
|||||||
LogPrintf("DoAutomaticDenominating --- error connecting \n");
|
LogPrintf("DoAutomaticDenominating --- error connecting \n");
|
||||||
strAutoDenomResult = _("Error connecting to Masternode.");
|
strAutoDenomResult = _("Error connecting to Masternode.");
|
||||||
dsq.time = 0; //remove node
|
dsq.time = 0; //remove node
|
||||||
return DoAutomaticDenominating();
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1605,6 +1608,7 @@ bool CDarksendPool::DoAutomaticDenominating(bool fDryRun)
|
|||||||
strAutoDenomResult = _("Mixing in progress...");
|
strAutoDenomResult = _("Mixing in progress...");
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
|
vecMasternodesUsed.push_back(pmn->vin); // postpone MN we wasn't able to connect to
|
||||||
i++;
|
i++;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -339,6 +339,9 @@ void CMasternodePayments::ProcessMessageMasternodePayments(CNode* pfrom, std::st
|
|||||||
{
|
{
|
||||||
if(!masternodeSync.IsBlockchainSynced()) return;
|
if(!masternodeSync.IsBlockchainSynced()) return;
|
||||||
|
|
||||||
|
if(fLiteMode) return; //disable all Darksend/Masternode related functionality
|
||||||
|
|
||||||
|
|
||||||
if (strCommand == "mnget") { //Masternode Payments Request Sync
|
if (strCommand == "mnget") { //Masternode Payments Request Sync
|
||||||
if(fLiteMode) return; //disable all Darksend/Masternode related functionality
|
if(fLiteMode) return; //disable all Darksend/Masternode related functionality
|
||||||
|
|
||||||
@ -595,7 +598,7 @@ void CMasternodePayments::CleanPaymentList()
|
|||||||
if(chainActive.Tip() == NULL) return;
|
if(chainActive.Tip() == NULL) return;
|
||||||
|
|
||||||
//keep up to five cycles for historical sake
|
//keep up to five cycles for historical sake
|
||||||
int nLimit = std::max(((int)mnodeman.size())*5, 1000);
|
int nLimit = std::max(((int)mnodeman.size())*2, 1000);
|
||||||
|
|
||||||
std::map<uint256, CMasternodePaymentWinner>::iterator it = mapMasternodePayeeVotes.begin();
|
std::map<uint256, CMasternodePaymentWinner>::iterator it = mapMasternodePayeeVotes.begin();
|
||||||
while(it != mapMasternodePayeeVotes.end()) {
|
while(it != mapMasternodePayeeVotes.end()) {
|
||||||
|
@ -324,6 +324,26 @@ void CMasternodeMan::CheckAndRemove(bool forceExpiredRemoval)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// remove expired mapSeenMasternodeBroadcast
|
||||||
|
map<uint256, CMasternodeBroadcast>::iterator it3 = mapSeenMasternodeBroadcast.begin();
|
||||||
|
while(it3 != mapSeenMasternodeBroadcast.end()){
|
||||||
|
if((*it3).second.sigTime < GetTime()-(MASTERNODE_MIN_MNP_SECONDS*2)){
|
||||||
|
mapSeenMasternodeBroadcast.erase(it3++);
|
||||||
|
} else {
|
||||||
|
++it3;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// remove expired mapSeenMasternodePing
|
||||||
|
map<uint256, CMasternodePing>::iterator it4 = mapSeenMasternodePing.begin();
|
||||||
|
while(it4 != mapSeenMasternodePing.end()){
|
||||||
|
if((*it4).second.sigTime < GetTime()-(MASTERNODE_REMOVAL_SECONDS*2)){
|
||||||
|
mapSeenMasternodePing.erase(it4++);
|
||||||
|
} else {
|
||||||
|
++it4;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void CMasternodeMan::Clear()
|
void CMasternodeMan::Clear()
|
||||||
|
Loading…
Reference in New Issue
Block a user