diff --git a/src/kernel.cpp b/src/kernel.cpp index 0fbb18e..fd3da3b 100644 --- a/src/kernel.cpp +++ b/src/kernel.cpp @@ -213,8 +213,8 @@ bool CheckStakeKernelHash(CBlockIndex* pindexPrev, unsigned int nBits, unsigned if (nTimeBlockFrom + nStakeMinAge > nTimeTx) // Min age requirement return error("CheckStakeKernelHash() : min age violation"); - if (nTimeBlockFrom + nStakeMaxAge < nTimeTx) // Max age requirement - return error("CheckStakeKernelHash() : max age violation"); + //if (nTimeBlockFrom + nStakeMaxAge < nTimeTx) // Max age requirement + //return error("CheckStakeKernelHash() : max age violation"); @@ -327,7 +327,7 @@ bool CheckKernel(CBlockIndex* pindexPrev, unsigned int nBits, int64_t nTime, con if (!block.ReadFromDisk(txindex.pos.nFile, txindex.pos.nBlockPos, false)) return false; - if ((block.GetBlockTime() + nStakeMinAge > nTime) || (block.GetBlockTime() + nStakeMaxAge < nTime)) + if ((block.GetBlockTime() + nStakeMinAge > nTime))// || (block.GetBlockTime() + nStakeMaxAge < nTime)) return false; // only count coins meeting min age requirement int nDepth; diff --git a/src/wallet.cpp b/src/wallet.cpp index e1aa97a..b0798a1 100644 --- a/src/wallet.cpp +++ b/src/wallet.cpp @@ -1748,8 +1748,8 @@ void CWallet::AvailableCoinsForStaking(vector& vCoins, unsigned int nSp if (pcoin->nTime + nStakeMinAge > nSpendTime) continue; // Filtering by tx timestamp instead of block timestamp may give false positives but never false negatives - if (pcoin->nTime + nStakeMaxAge < nSpendTime) - continue; + //if (pcoin->nTime + nStakeMaxAge < nSpendTime) + // continue; } if (pcoin->GetBlocksToMaturity() > 0) @@ -3494,8 +3494,8 @@ bool CWallet::CreateCoinStake(const CKeyStore& keystore, unsigned int nBits, int if (nTimeWeight < nStakeMinAge) continue; // Do not add input that is too old - if (nTimeWeight > nStakeMaxAge) - continue; + //if (nTimeWeight > nStakeMaxAge) + // continue; txNew.vin.push_back(CTxIn(pcoin.first->GetHash(), pcoin.second)); nCredit += pcoin.first->vout[pcoin.second].nValue;