aboutsummaryrefslogtreecommitdiff
path: root/src/test/sighash_tests.cpp
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2016-11-11 16:23:17 -0800
committerPieter Wuille <pieter.wuille@gmail.com>2016-12-02 18:37:43 -0800
commit81e3228fcb33e8ed32d8b9fbe917444ba080073a (patch)
tree345dd81bc1661003ea8957fe1f69050b3187d4ac /src/test/sighash_tests.cpp
parent42fd8dee302fec55ba0970e2f1378edc2797e4ff (diff)
downloadbitcoin-81e3228fcb33e8ed32d8b9fbe917444ba080073a.tar.xz
Make CTransaction actually immutable
Diffstat (limited to 'src/test/sighash_tests.cpp')
-rw-r--r--src/test/sighash_tests.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/test/sighash_tests.cpp b/src/test/sighash_tests.cpp
index 38d58e7ab0..a524f5b946 100644
--- a/src/test/sighash_tests.cpp
+++ b/src/test/sighash_tests.cpp
@@ -184,7 +184,7 @@ BOOST_AUTO_TEST_CASE(sighash_from_data)
std::string raw_tx, raw_script, sigHashHex;
int nIn, nHashType;
uint256 sh;
- CTransaction tx;
+ CTransactionRef tx;
CScript scriptCode = CScript();
try {
@@ -199,7 +199,7 @@ BOOST_AUTO_TEST_CASE(sighash_from_data)
stream >> tx;
CValidationState state;
- BOOST_CHECK_MESSAGE(CheckTransaction(tx, state), strTest);
+ BOOST_CHECK_MESSAGE(CheckTransaction(*tx, state), strTest);
BOOST_CHECK(state.IsValid());
std::vector<unsigned char> raw = ParseHex(raw_script);
@@ -209,7 +209,7 @@ BOOST_AUTO_TEST_CASE(sighash_from_data)
continue;
}
- sh = SignatureHash(scriptCode, tx, nIn, nHashType, 0, SIGVERSION_BASE);
+ sh = SignatureHash(scriptCode, *tx, nIn, nHashType, 0, SIGVERSION_BASE);
BOOST_CHECK_MESSAGE(sh.GetHex() == sigHashHex, strTest);
}
}