Rawtx->hex for marmara
This commit is contained in:
@@ -496,7 +496,7 @@ UniValue MarmaraLock(uint64_t txfee,int64_t amount,int32_t height)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
result.push_back(Pair("result",(char *)"success"));
|
result.push_back(Pair("result",(char *)"success"));
|
||||||
result.push_back(Pair("rawtx",rawtx));
|
result.push_back(Pair("hex",rawtx));
|
||||||
return(result);
|
return(result);
|
||||||
}
|
}
|
||||||
} else errorstr = (char *)"insufficient funds";
|
} else errorstr = (char *)"insufficient funds";
|
||||||
@@ -600,7 +600,7 @@ UniValue MarmaraSettlement(uint64_t txfee,uint256 refbatontxid)
|
|||||||
mtx.vout.push_back(MakeCC1of2vout(EVAL_MARMARA,change,Marmarapk,pk));
|
mtx.vout.push_back(MakeCC1of2vout(EVAL_MARMARA,change,Marmarapk,pk));
|
||||||
rawtx = FinalizeCCTx(0,cp,mtx,mypk,txfee,MarmaraLoopOpret('S',createtxid,mypk,0,refmatures,currency),pubkeys);
|
rawtx = FinalizeCCTx(0,cp,mtx,mypk,txfee,MarmaraLoopOpret('S',createtxid,mypk,0,refmatures,currency),pubkeys);
|
||||||
result.push_back(Pair("result",(char *)"success"));
|
result.push_back(Pair("result",(char *)"success"));
|
||||||
result.push_back(Pair("rawtx",rawtx));
|
result.push_back(Pair("hex",rawtx));
|
||||||
return(result);
|
return(result);
|
||||||
} else remaining -= inputsum;
|
} else remaining -= inputsum;
|
||||||
if ( mtx.vin.size() >= CC_MAXVINS - MARMARA_VINS )
|
if ( mtx.vin.size() >= CC_MAXVINS - MARMARA_VINS )
|
||||||
@@ -616,7 +616,7 @@ UniValue MarmaraSettlement(uint64_t txfee,uint256 refbatontxid)
|
|||||||
rawtx = FinalizeCCTx(0,cp,mtx,mypk,txfee,MarmaraLoopOpret('D',createtxid,mypk,-remaining,refmatures,currency),pubkeys);
|
rawtx = FinalizeCCTx(0,cp,mtx,mypk,txfee,MarmaraLoopOpret('D',createtxid,mypk,-remaining,refmatures,currency),pubkeys);
|
||||||
result.push_back(Pair("result",(char *)"error"));
|
result.push_back(Pair("result",(char *)"error"));
|
||||||
result.push_back(Pair("error",(char *)"insufficient funds"));
|
result.push_back(Pair("error",(char *)"insufficient funds"));
|
||||||
result.push_back(Pair("rawtx",rawtx));
|
result.push_back(Pair("hex",rawtx));
|
||||||
result.push_back(Pair("remaining",ValueFromAmount(remaining)));
|
result.push_back(Pair("remaining",ValueFromAmount(remaining)));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -731,7 +731,7 @@ UniValue MarmaraReceive(uint64_t txfee,CPubKey senderpk,int64_t amount,std::stri
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
result.push_back(Pair("result",(char *)"success"));
|
result.push_back(Pair("result",(char *)"success"));
|
||||||
result.push_back(Pair("rawtx",rawtx));
|
result.push_back(Pair("hex",rawtx));
|
||||||
result.push_back(Pair("funcid","R"));
|
result.push_back(Pair("funcid","R"));
|
||||||
result.push_back(Pair("createtxid",createtxid.GetHex()));
|
result.push_back(Pair("createtxid",createtxid.GetHex()));
|
||||||
if ( batontxid != zeroid )
|
if ( batontxid != zeroid )
|
||||||
@@ -787,7 +787,7 @@ UniValue MarmaraIssue(uint64_t txfee,uint8_t funcid,CPubKey receiverpk,int64_t a
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
result.push_back(Pair("result",(char *)"success"));
|
result.push_back(Pair("result",(char *)"success"));
|
||||||
result.push_back(Pair("rawtx",rawtx));
|
result.push_back(Pair("hex",rawtx));
|
||||||
char str[2]; str[0] = funcid, str[1] = 0;
|
char str[2]; str[0] = funcid, str[1] = 0;
|
||||||
result.push_back(Pair("funcid",str));
|
result.push_back(Pair("funcid",str));
|
||||||
result.push_back(Pair("createtxid",createtxid.GetHex()));
|
result.push_back(Pair("createtxid",createtxid.GetHex()));
|
||||||
@@ -1025,7 +1025,7 @@ UniValue MarmaraPoolPayout(uint64_t txfee,int32_t firstheight,double perc,char *
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
result.push_back(Pair("result",(char *)"success"));
|
result.push_back(Pair("result",(char *)"success"));
|
||||||
result.push_back(Pair("rawtx",rawtx));
|
result.push_back(Pair("hex",rawtx));
|
||||||
if ( totalpayout > 0 && total > totalpayout-txfee )
|
if ( totalpayout > 0 && total > totalpayout-txfee )
|
||||||
{
|
{
|
||||||
result.push_back(Pair("firstheight",firstheight));
|
result.push_back(Pair("firstheight",firstheight));
|
||||||
|
|||||||
@@ -5662,7 +5662,6 @@ bool static LoadBlockIndexDB()
|
|||||||
if (pindex->nStatus & BLOCK_HAVE_DATA) {
|
if (pindex->nStatus & BLOCK_HAVE_DATA) {
|
||||||
setBlkDataFiles.insert(pindex->nFile);
|
setBlkDataFiles.insert(pindex->nFile);
|
||||||
}
|
}
|
||||||
//komodo_pindex_init(pindex,(int32_t)pindex->GetHeight());
|
|
||||||
}
|
}
|
||||||
//fprintf(stderr,"load blockindexDB %u\n",(uint32_t)time(NULL));
|
//fprintf(stderr,"load blockindexDB %u\n",(uint32_t)time(NULL));
|
||||||
for (std::set<int>::iterator it = setBlkDataFiles.begin(); it != setBlkDataFiles.end(); it++)
|
for (std::set<int>::iterator it = setBlkDataFiles.begin(); it != setBlkDataFiles.end(); it++)
|
||||||
|
|||||||
Reference in New Issue
Block a user