Cleanup staking and fee consistency for stake tx

This commit is contained in:
miketout
2018-10-03 10:31:01 -07:00
parent b3e3f61826
commit 86e31e3dfc
4 changed files with 32 additions and 14 deletions

View File

@@ -193,9 +193,8 @@ bool MakeGuardedOutput(CAmount value, CPubKey &dest, CTransaction &stakeTx, CTxO
return false;
}
// This is only needed to create a spend for cheating. normal spend and signing should work
// for vins
bool MakeGuardedSpend(CTxIn &vin, CPubKey &dest, CTransaction *pCheater)
// this creates a spend using a stake transaction
bool MakeGuardedSpend(CTxIn &vin, CPubKey &dest, CTransaction &pCheater)
{
CCcontract_info *cp,C;

View File

@@ -18,6 +18,8 @@
#include "streams.h"
#include "script/script.h"
#define DEFAULT_STAKE_TXFEE 10000
class CStakeParams
{
public:
@@ -61,6 +63,8 @@ bool ValidateStakeTransaction(const CTransaction &stakeTx, CStakeParams &stakePa
bool MakeGuardedOutput(CAmount value, CPubKey &dest, CTransaction &stakeTx, CTxOut &vout);
bool MakeGuardedSpend(CTxIn &vin, CPubKey &dest, CTransaction &pCheater);
bool CoinbaseGuardValidate(struct CCcontract_info *cp,Eval* eval,const CTransaction &tx, uint32_t nIn);
UniValue CoinbaseGuardInfo();