aboutsummaryrefslogtreecommitdiff
path: root/src/rpc
diff options
context:
space:
mode:
authorAndrew Chow <achow101-github@achow101.com>2017-08-11 12:21:14 -0700
committerAndrew Chow <achow101-github@achow101.com>2017-08-17 10:42:51 -0700
commit6bbdafcdc4f9d9e3f9de72ed686c060fb4b8b465 (patch)
tree2a3cabde520fbe74bde9f434f4a1d724840c73f8 /src/rpc
parente029c6e709d251809aa04edc08f76a077a2443e7 (diff)
downloadbitcoin-6bbdafcdc4f9d9e3f9de72ed686c060fb4b8b465.tar.xz
Pass serialization flags and whether to include hex to TxToUniv
Diffstat (limited to 'src/rpc')
-rw-r--r--src/rpc/blockchain.cpp2
-rw-r--r--src/rpc/rawtransaction.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/rpc/blockchain.cpp b/src/rpc/blockchain.cpp
index d65e107e3c..f3c65a2e01 100644
--- a/src/rpc/blockchain.cpp
+++ b/src/rpc/blockchain.cpp
@@ -125,7 +125,7 @@ UniValue blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool tx
if(txDetails)
{
UniValue objTx(UniValue::VOBJ);
- TxToUniv(*tx, uint256(), objTx);
+ TxToUniv(*tx, uint256(), objTx, true, RPCSerializationFlags());
txs.push_back(objTx);
}
else
diff --git a/src/rpc/rawtransaction.cpp b/src/rpc/rawtransaction.cpp
index ad6067db46..0d0c6449b7 100644
--- a/src/rpc/rawtransaction.cpp
+++ b/src/rpc/rawtransaction.cpp
@@ -41,7 +41,7 @@ void TxToJSON(const CTransaction& tx, const uint256 hashBlock, UniValue& entry)
// Blockchain contextual information (confirmations and blocktime) is not
// available to code in bitcoin-common, so we query them here and push the
// data into the returned UniValue.
- TxToUniv(tx, uint256(), entry);
+ TxToUniv(tx, uint256(), entry, true, RPCSerializationFlags());
if (!hashBlock.IsNull()) {
entry.push_back(Pair("blockhash", hashBlock.GetHex()));
@@ -480,7 +480,7 @@ UniValue decoderawtransaction(const JSONRPCRequest& request)
throw JSONRPCError(RPC_DESERIALIZATION_ERROR, "TX decode failed");
UniValue result(UniValue::VOBJ);
- TxToUniv(CTransaction(std::move(mtx)), uint256(), result);
+ TxToUniv(CTransaction(std::move(mtx)), uint256(), result, false);
return result;
}