Browse Source

Remove dead code relating to interest

pull/332/head
Duke 1 year ago
parent
commit
c69a47dd61
  1. 32
      src/wallet/wallet.cpp

32
src/wallet/wallet.cpp

@ -3303,7 +3303,7 @@ CAmount CWallet::GetImmatureWatchOnlyBalance() const
void CWallet::AvailableCoins(vector<COutput>& vCoins, bool fOnlyConfirmed, const CCoinControl *coinControl, bool fIncludeZeroValue, bool fIncludeCoinBase) const
{
uint64_t interest,*ptr;
uint64_t *ptr;
vCoins.clear();
{
@ -3336,34 +3336,8 @@ void CWallet::AvailableCoins(vector<COutput>& vCoins, bool fOnlyConfirmed, const
!IsLockedCoin((*it).first, i) && (pcoin->vout[i].nValue > 0 || fIncludeZeroValue) &&
(!coinControl || !coinControl->HasSelected() || coinControl->IsSelected((*it).first, i)))
{
if ( 1 ) {
uint32_t locktime; int32_t txheight; CBlockIndex *tipindex;
if ( SMART_CHAIN_SYMBOL[0] == 0 && chainActive.LastTip() != 0 && chainActive.LastTip()->GetHeight() >= 60000 )
{
if ( pcoin->vout[i].nValue >= 10*COIN )
{
if ( (tipindex= chainActive.LastTip()) != 0 )
{
interest = 0;
} else interest = 0;
if ( interest != 0 )
{
ptr = (uint64_t *)&pcoin->vout[i].interest;
(*ptr) = interest;
//pcoin->vout[i].nValue += interest;
} else {
ptr = (uint64_t *)&pcoin->vout[i].interest;
(*ptr) = 0;
}
} else {
ptr = (uint64_t *)&pcoin->vout[i].interest;
(*ptr) = 0;
}
} else {
ptr = (uint64_t *)&pcoin->vout[i].interest;
(*ptr) = 0;
}
}
ptr = (uint64_t *)&pcoin->vout[i].interest;
(*ptr) = 0;
vCoins.push_back(COutput(pcoin, i, nDepth, (mine & ISMINE_SPENDABLE) != ISMINE_NO));
}
}

Loading…
Cancel
Save