diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2017-12-13 13:32:00 +0100 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2017-12-13 14:05:25 +0100 |
commit | 68e021e3a35d1e88d6075ea8b05a8e3a40a64e29 (patch) | |
tree | a602d99d1d242f8a603127dcbc435944e5cea52f /src/bench | |
parent | ba2f19504c6b1302a93accbb50383f422c54df43 (diff) | |
parent | fbf327b13868861c2877c5754caf5a9816f2603c (diff) |
Merge #11558: Minimal code changes to allow msvc compilation
fbf327b Minimal code changes to allow msvc compilation. (Aaron Clauson)
Pull request description:
These changes are required to allow the Bitcoin source to build with Microsoft's C++ compiler (#11562 is also required).
I looked around for a better place for the typedef of ssize_t which is in random.h. The best candidate looks like src/compat.h but I figured including that header in random.h is a bigger change than the typedef. Note that the same typedef is in at least two other places including the OpenSSL and Berkeley DB headers so some of the Bitcoin code already picks it up.
Tree-SHA512: aa6cc6283015e08ab074641f9abdc116c4dc58574dc90f75e7a5af4cc82946d3052370e5cbe855fb6180c00f8dc66997d3724ff0412e4b7417e51b6602154825
Diffstat (limited to 'src/bench')
-rw-r--r-- | src/bench/base58.cpp | 2 | ||||
-rw-r--r-- | src/bench/checkqueue.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/bench/base58.cpp b/src/bench/base58.cpp index 8f6d07ac16..2d9a9f2908 100644 --- a/src/bench/base58.cpp +++ b/src/bench/base58.cpp @@ -22,7 +22,7 @@ static void Base58Encode(benchmark::State& state) } }; while (state.KeepRunning()) { - EncodeBase58(buff.begin(), buff.end()); + EncodeBase58(buff.data(), buff.data() + buff.size()); } } diff --git a/src/bench/checkqueue.cpp b/src/bench/checkqueue.cpp index 7e63e820db..35750aa1b6 100644 --- a/src/bench/checkqueue.cpp +++ b/src/bench/checkqueue.cpp @@ -19,7 +19,7 @@ static const int MIN_CORES = 2; static const size_t BATCHES = 101; static const size_t BATCH_SIZE = 30; static const int PREVECTOR_SIZE = 28; -static const int QUEUE_BATCH_SIZE = 128; +static const unsigned int QUEUE_BATCH_SIZE = 128; static void CCheckQueueSpeed(benchmark::State& state) { struct FakeJobNoWork { |