This commit is contained in:
jl777
2016-11-11 20:15:05 -03:00
parent 6ed911ff39
commit 4a4e912bbe
10 changed files with 87 additions and 43 deletions

View File

@@ -18,7 +18,7 @@
#include "utilmoneystr.h"
#include "zcash/Note.hpp"
#include "crypter.h"
#include "coins.h"
#include <assert.h>
#include <boost/algorithm/string/replace.hpp>
@@ -2402,9 +2402,12 @@ bool CWallet::SelectCoins(const CAmount& nTargetValue, set<pair<const CWalletTx*
interest = komodo_interest(chainActive.Tip()->nHeight,out.tx->vout[out.i].nValue,out.tx->nLockTime,chainActive.Tip()->nTime);
#ifdef KOMODO_ENABLE_INTEREST
if ( ASSETCHAINS_SYMBOL[0] == 0 && txheight >= 60000 )
{
printf("nValueRet %.8f += interest %.8f ht.%d lock.%u tip.%u\n",(double)nValueRet/COIN,(double)interest/COIN,nHeight,tx.nLockTime,tiptime);
nValueRet += interest;
#endif
}
fprintf(stderr,"interest %llu from %llu lock.%u tip.%u\n",(long long)interest,(long long)out.tx->vout[out.i].nValue,out.tx->nLockTime,chainActive.Tip()->nTime);
#endif
setCoinsRet.insert(make_pair(out.tx, out.i));
}
return (nValueRet >= nTargetValue);