From ae775b5b311982a3d932a9e34ddc94ce597dcaaf Mon Sep 17 00:00:00 2001 From: Jeff Garzik Date: Mon, 23 Jun 2014 23:10:24 -0400 Subject: Consolidate CTransaction hex encode/decode into core_io.h, core_{read,write}.cpp --- src/rpcwallet.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/rpcwallet.cpp') diff --git a/src/rpcwallet.cpp b/src/rpcwallet.cpp index 5b83fe900e..667ca33ce1 100644 --- a/src/rpcwallet.cpp +++ b/src/rpcwallet.cpp @@ -4,6 +4,7 @@ // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include "base58.h" +#include "core_io.h" #include "rpcserver.h" #include "init.h" #include "net.h" @@ -1550,9 +1551,7 @@ Value gettransaction(const Array& params, bool fHelp) ListTransactions(wtx, "*", 0, false, details, filter); entry.push_back(Pair("details", details)); - CDataStream ssTx(SER_NETWORK, PROTOCOL_VERSION); - ssTx << static_cast(wtx); - string strHex = HexStr(ssTx.begin(), ssTx.end()); + string strHex = EncodeHexTx(static_cast(wtx)); entry.push_back(Pair("hex", strHex)); return entry; -- cgit v1.2.3