aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/blockchain.cpp
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2016-11-10 17:26:00 -0800
committerPieter Wuille <pieter.wuille@gmail.com>2016-11-19 17:51:09 -0800
commit1662b437b33b7ec5a1723f6ae6187d3bdd06f593 (patch)
tree00b734409ca0ff817c36c000deae676df3cf16e2 /src/rpc/blockchain.cpp
parentda60506fc80f6a78f1b271a9a53b956b49b37234 (diff)
downloadbitcoin-1662b437b33b7ec5a1723f6ae6187d3bdd06f593.tar.xz
Make CBlock::vtx a vector of shared_ptr<CTransaction>
Diffstat (limited to 'src/rpc/blockchain.cpp')
-rw-r--r--src/rpc/blockchain.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/rpc/blockchain.cpp b/src/rpc/blockchain.cpp
index 8caea14adb..154107c0dc 100644
--- a/src/rpc/blockchain.cpp
+++ b/src/rpc/blockchain.cpp
@@ -119,16 +119,16 @@ UniValue blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool tx
result.push_back(Pair("versionHex", strprintf("%08x", block.nVersion)));
result.push_back(Pair("merkleroot", block.hashMerkleRoot.GetHex()));
UniValue txs(UniValue::VARR);
- BOOST_FOREACH(const CTransaction&tx, block.vtx)
+ for(const auto& tx : block.vtx)
{
if(txDetails)
{
UniValue objTx(UniValue::VOBJ);
- TxToJSON(tx, uint256(), objTx);
+ TxToJSON(*tx, uint256(), objTx);
txs.push_back(objTx);
}
else
- txs.push_back(tx.GetHash().GetHex());
+ txs.push_back(tx->GetHash().GetHex());
}
result.push_back(Pair("tx", txs));
result.push_back(Pair("time", block.GetBlockTime()));