From 8a7fc182f026dd252eb58511a8f03d0676b3c256 Mon Sep 17 00:00:00 2001 From: dimxy Date: Wed, 6 Mar 2019 16:36:12 +0500 Subject: [PATCH] Fixed tokenfillbid failure (#1312) * commented preventcc call * preventcc call restored preventccvouts ++ added for 'B' --- src/cc/assets.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cc/assets.cpp b/src/cc/assets.cpp index 6e57e816b..9ae4cc1eb 100644 --- a/src/cc/assets.cpp +++ b/src/cc/assets.cpp @@ -297,6 +297,7 @@ bool AssetsValidate(struct CCcontract_info *cpAssets,Eval* eval,const CTransacti return eval->Invalid("vout2 doesnt go to origpubkey fillbuy"); else if ( inputs != tx.vout[2].nValue + tx.vout[4].nValue ) return eval->Invalid("asset inputs doesnt match vout2+3 fillbuy"); + preventCCvouts ++; } else if( ConstrainVout(tx.vout[2], 1, origTokensCCaddr, inputs) == 0 ) // tokens to originator cc addr (tokens+nonfungible evals) return eval->Invalid("vout2 doesnt match inputs fillbuy"); @@ -468,7 +469,7 @@ bool AssetsValidate(struct CCcontract_info *cpAssets,Eval* eval,const CTransacti } // what does this do? - bool bPrevent = PreventCC(eval, tx, preventCCvins, numvins, preventCCvouts, numvouts); + bool bPrevent = PreventCC(eval, tx, preventCCvins, numvins, preventCCvouts, numvouts); // seems we do not need this call as we already checked vouts well //std::cerr << "AssetsValidate() PreventCC returned=" << bPrevent << std::endl; return (bPrevent); }