Changeset View
Changeset View
Standalone View
Standalone View
src/rpc/mining.cpp
Show First 20 Lines • Show All 627 Lines • ▼ Show 20 Lines | for (const auto &it : pblock->vtx) { | ||||
for (const CTxIn &in : tx.vin) { | for (const CTxIn &in : tx.vin) { | ||||
if (setTxIndex.count(in.prevout.GetTxId())) { | if (setTxIndex.count(in.prevout.GetTxId())) { | ||||
deps.push_back(setTxIndex[in.prevout.GetTxId()]); | deps.push_back(setTxIndex[in.prevout.GetTxId()]); | ||||
} | } | ||||
} | } | ||||
entry.pushKV("depends", deps); | entry.pushKV("depends", deps); | ||||
int index_in_template = i - 1; | int index_in_template = i - 1; | ||||
entry.push_back( | entry.push_back(Pair( | ||||
Pair("fee", pblocktemplate->vTxFees[index_in_template] / SATOSHI)); | "fee", pblocktemplate->entries[index_in_template].fees / SATOSHI)); | ||||
int64_t nTxSigOps = pblocktemplate->vTxSigOpsCount[index_in_template]; | int64_t nTxSigOps = | ||||
pblocktemplate->entries[index_in_template].sigOpCount; | |||||
entry.pushKV("sigops", nTxSigOps); | entry.pushKV("sigops", nTxSigOps); | ||||
transactions.push_back(entry); | transactions.push_back(entry); | ||||
} | } | ||||
UniValue aux(UniValue::VOBJ); | UniValue aux(UniValue::VOBJ); | ||||
aux.push_back( | aux.push_back( | ||||
Pair("flags", HexStr(COINBASE_FLAGS.begin(), COINBASE_FLAGS.end()))); | Pair("flags", HexStr(COINBASE_FLAGS.begin(), COINBASE_FLAGS.end()))); | ||||
▲ Show 20 Lines • Show All 190 Lines • Show Last 20 Lines |