aboutsummaryrefslogtreecommitdiff
path: root/src/test/test_bitcoin.h
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2017-06-07 12:03:17 -0700
committerPieter Wuille <pieter.wuille@gmail.com>2017-06-07 12:08:39 -0700
commite945848582160b23fa0bc6f797e2bd8ac676ee0e (patch)
tree8f21846a56c3ee99978f9a64514ae8be2fa378ae /src/test/test_bitcoin.h
parent2fcd9cc86bfce944e3312e9a24685403250f3bdc (diff)
scripted-diff: Use new naming style for insecure_rand* functions
-BEGIN VERIFY SCRIPT- sed -i 's/\<insecure_randbits(/InsecureRandBits(/g' src/test/*.cpp src/test/*.h src/wallet/test/*.cpp sed -i 's/\<insecure_randbool(/InsecureRandBool(/g' src/test/*.cpp src/test/*.h src/wallet/test/*.cpp sed -i 's/\<insecure_randrange(/InsecureRandRange(/g' src/test/*.cpp src/test/*.h src/wallet/test/*.cpp sed -i 's/\<insecure_randbytes(/InsecureRandBytes(/g' src/test/*.cpp src/test/*.h src/wallet/test/*.cpp sed -i 's/\<insecure_rand256(/InsecureRand256(/g' src/test/*.cpp src/test/*.h src/wallet/test/*.cpp sed -i 's/\<insecure_rand(/InsecureRand32(/g' src/test/*.cpp src/test/*.h src/wallet/test/*.cpp sed -i 's/\<seed_insecure_rand(/SeedInsecureRand(/g' src/test/*.cpp src/test/*.h src/wallet/test/*.cpp -END VERIFY SCRIPT-
Diffstat (limited to 'src/test/test_bitcoin.h')
-rw-r--r--src/test/test_bitcoin.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/test/test_bitcoin.h b/src/test/test_bitcoin.h
index 821ae060b5..0087eeb2d7 100644
--- a/src/test/test_bitcoin.h
+++ b/src/test/test_bitcoin.h
@@ -18,7 +18,7 @@
extern uint256 insecure_rand_seed;
extern FastRandomContext insecure_rand_ctx;
-static inline void seed_insecure_rand(bool fDeterministic = false)
+static inline void SeedInsecureRand(bool fDeterministic = false)
{
if (fDeterministic) {
insecure_rand_seed = uint256();
@@ -28,12 +28,12 @@ static inline void seed_insecure_rand(bool fDeterministic = false)
insecure_rand_ctx = FastRandomContext(insecure_rand_seed);
}
-static inline uint32_t insecure_rand() { return insecure_rand_ctx.rand32(); }
-static inline uint256 insecure_rand256() { return insecure_rand_ctx.rand256(); }
-static inline uint64_t insecure_randbits(int bits) { return insecure_rand_ctx.randbits(bits); }
-static inline uint64_t insecure_randrange(uint64_t range) { return insecure_rand_ctx.randrange(range); }
-static inline bool insecure_randbool() { return insecure_rand_ctx.randbool(); }
-static inline std::vector<unsigned char> insecure_randbytes(size_t len) { return insecure_rand_ctx.randbytes(len); }
+static inline uint32_t InsecureRand32() { return insecure_rand_ctx.rand32(); }
+static inline uint256 InsecureRand256() { return insecure_rand_ctx.rand256(); }
+static inline uint64_t InsecureRandBits(int bits) { return insecure_rand_ctx.randbits(bits); }
+static inline uint64_t InsecureRandRange(uint64_t range) { return insecure_rand_ctx.randrange(range); }
+static inline bool InsecureRandBool() { return insecure_rand_ctx.randbool(); }
+static inline std::vector<unsigned char> InsecureRandBytes(size_t len) { return insecure_rand_ctx.randbytes(len); }
/** Basic testing setup.
* This just configures logging and chain parameters.