This commit is contained in:
blackjok3r
2019-03-28 14:56:51 +08:00
parent de64689085
commit 87b039a267
2 changed files with 2 additions and 3 deletions

View File

@@ -263,7 +263,7 @@ bool RewardsValidate(struct CCcontract_info *cp,Eval* eval,const CTransaction &t
if ( numvins == 1 && tx.vout[0].scriptPubKey.IsPayToCryptoCondition() == 0 )
{
if ( tx.vout[1].nValue != 10000 )
return eval->Invalid("wrong marker vour value");
return eval->Invalid("wrong marker vout value");
else if ( tx.vout[1].scriptPubKey != tx.vout[0].scriptPubKey )
return eval->Invalid("unlock recover tx vout.1 mismatched scriptPubKey");
else if ( tx.vout[0].scriptPubKey != vinTx.vout[1].scriptPubKey )
@@ -285,7 +285,6 @@ bool RewardsValidate(struct CCcontract_info *cp,Eval* eval,const CTransaction &t
else if ( tx.vout[1].scriptPubKey != vinTx.vout[1].scriptPubKey )
return eval->Invalid("unlock tx vout.1 mismatched scriptPubKey");
amount = vinTx.vout[0].nValue;
reward = RewardsCalc(amount,tx.vin[0].prevout.hash,APR,minseconds,maxseconds,mindeposit);
if ( RewardsExactAmounts(cp,eval,tx,txfee+tx.vout[1].nValue,sbits,fundingtxid) == 0 )
return false;
else if ( tx.vout[1].nValue > amount+reward )

View File

@@ -1383,7 +1383,7 @@ bool CheckTransactionWithoutProofVerification(uint32_t tiptime,const CTransactio
}
}
if ( txout.scriptPubKey.size() > IGUANA_MAXSCRIPTSIZE )
return state.DoS(100, error("CheckTransaction(): txout.scriptPubKey.size() too big"),REJECT_INVALID, "bad-txns-vout-negative");
return state.DoS(100, error("CheckTransaction(): txout.scriptPubKey.size() too big"),REJECT_INVALID, "bad-txns-opret-too-big");
nValueOut += txout.nValue;
if (!MoneyRange(nValueOut))
return state.DoS(100, error("CheckTransaction(): txout total out of range"),