aboutsummaryrefslogtreecommitdiff
path: root/src/test/bloom_tests.cpp
diff options
context:
space:
mode:
authorMeshCollider <dobsonsa68@gmail.com>2017-07-11 21:37:53 +1200
committerMeshCollider <dobsonsa68@gmail.com>2017-09-08 10:36:26 +1200
commit592404f03f2b734351d734f0c9ca1fdce997321b (patch)
tree463d2c31825679c76f11445366b6736702b2824c /src/test/bloom_tests.cpp
parentd81dccf191a48a6b59c3747d7b4ccbe3535dde40 (diff)
Changing &vec[0] to vec.data(), what 9804 missed
Diffstat (limited to 'src/test/bloom_tests.cpp')
-rw-r--r--src/test/bloom_tests.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/test/bloom_tests.cpp b/src/test/bloom_tests.cpp
index 2085b5cb2b..9274ceefcb 100644
--- a/src/test/bloom_tests.cpp
+++ b/src/test/bloom_tests.cpp
@@ -154,8 +154,8 @@ BOOST_AUTO_TEST_CASE(bloom_match)
COutPoint prevOutPoint(uint256S("0x90c122d70786e899529d71dbeba91ba216982fb6ba58f3bdaab65e73b7e9260b"), 0);
{
std::vector<unsigned char> data(32 + sizeof(unsigned int));
- memcpy(&data[0], prevOutPoint.hash.begin(), 32);
- memcpy(&data[32], &prevOutPoint.n, sizeof(unsigned int));
+ memcpy(data.data(), prevOutPoint.hash.begin(), 32);
+ memcpy(data.data()+32, &prevOutPoint.n, sizeof(unsigned int));
filter.insert(data);
}
BOOST_CHECK_MESSAGE(filter.IsRelevantAndUpdate(tx), "Simple Bloom filter didn't match manually serialized COutPoint");