From d4015ad408af3ae508f051ab9971de02bea74cbc Mon Sep 17 00:00:00 2001 From: jl777 Date: Sun, 10 Feb 2019 11:48:28 -1100 Subject: [PATCH] Qr --- src/cc/rogue_rpc.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/cc/rogue_rpc.cpp b/src/cc/rogue_rpc.cpp index a9dccc911..d5fe86b1d 100644 --- a/src/cc/rogue_rpc.cpp +++ b/src/cc/rogue_rpc.cpp @@ -709,7 +709,7 @@ UniValue rogue_register(uint64_t txfee,struct CCcontract_info *cp,cJSON *params) CCaddr1of2set(cp,roguepk,roguepk,cp->CCpriv,destaddr); mtx.vout.push_back(MakeTokensCC1vout(cp->evalcode, 1, burnpk)); - std::vector vopretFinish, vopret2; uint8_t e, f; uint256 tokenid; std::vector voutPubkeys, voutPubkeysEmpty; int32_t didtx = 0; + std::vector vopretFinish, vopret2; uint8_t e, funcid; uint256 tokenid; std::vector voutPubkeys, voutPubkeysEmpty; int32_t didtx = 0; CScript opretRegister = rogue_registeropret(gametxid, playertxid); if ( playertxid != zeroid ) { @@ -717,10 +717,10 @@ UniValue rogue_register(uint64_t txfee,struct CCcontract_info *cp,cJSON *params) voutPubkeysEmpty.push_back(burnpk); if ( GetTransaction(playertxid,playertx,hashBlock,false) != 0 ) { - if ( DecodeTokenOpRet(playertx.vout.back().scriptPubKey, e, tokenid, voutPubkeys, vopretFinish, vopret2) != 0) + if ( (funcid= DecodeTokenOpRet(playertx.vout.back().scriptPubKey, e, tokenid, voutPubkeys, vopretFinish, vopret2)) != 0) { // if token in the opret didtx = 1; - if ( tokenid == zeroid ) + if ( funcid == 'c' ) tokenid = playertxid; vopretFinish.resize(0); rawtx = FinalizeCCTx(0, cp, mtx, mypk, txfee,