File tree Expand file tree Collapse file tree 4 files changed +2
-23
lines changed Expand file tree Collapse file tree 4 files changed +2
-23
lines changed Original file line number Diff line number Diff line change @@ -121,7 +121,6 @@ class TestPayloadVisitor : public boost::static_visitor<bool>
121
121
BOOST_AUTO_TEST_CASE (base58_keys_valid_parse)
122
122
{
123
123
UniValue tests = read_json (std::string (json_tests::base58_keys_valid, json_tests::base58_keys_valid + sizeof (json_tests::base58_keys_valid)));
124
- std::vector<unsigned char > result;
125
124
CBitcoinSecret secret;
126
125
CBitcoinAddress addr;
127
126
SelectParams (CBaseChainParams::MAIN);
@@ -179,7 +178,6 @@ BOOST_AUTO_TEST_CASE(base58_keys_valid_parse)
179
178
BOOST_AUTO_TEST_CASE (base58_keys_valid_gen)
180
179
{
181
180
UniValue tests = read_json (std::string (json_tests::base58_keys_valid, json_tests::base58_keys_valid + sizeof (json_tests::base58_keys_valid)));
182
- std::vector<unsigned char > result;
183
181
184
182
for (unsigned int idx = 0 ; idx < tests.size (); idx++) {
185
183
UniValue test = tests[idx];
@@ -247,7 +245,6 @@ BOOST_AUTO_TEST_CASE(base58_keys_valid_gen)
247
245
BOOST_AUTO_TEST_CASE (base58_keys_invalid)
248
246
{
249
247
UniValue tests = read_json (std::string (json_tests::base58_keys_invalid, json_tests::base58_keys_invalid + sizeof (json_tests::base58_keys_invalid))); // Negative testcases
250
- std::vector<unsigned char > result;
251
248
CBitcoinSecret secret;
252
249
CBitcoinAddress addr;
253
250
Original file line number Diff line number Diff line change @@ -122,7 +122,6 @@ BOOST_AUTO_TEST_CASE(pmt_malleability)
122
122
std::vector<bool > vMatch = boost::assign::list_of (false )(false )(false )(false )(false )(false )(false )(false )(false )(true )(true )(false );
123
123
124
124
CPartialMerkleTree tree (vTxid, vMatch);
125
- std::vector<uint256> vTxid2;
126
125
std::vector<unsigned int > vIndex;
127
126
BOOST_CHECK (tree.ExtractMatches (vTxid, vIndex).IsNull ());
128
127
}
Original file line number Diff line number Diff line change 18
18
19
19
using namespace std ;
20
20
21
- UniValue
22
- createArgs (int nRequired, const char * address1=NULL , const char * address2=NULL )
23
- {
24
- UniValue result (UniValue::VARR);
25
- result.push_back (nRequired);
26
- UniValue addresses (UniValue::VARR);
27
- if (address1) addresses.push_back (address1);
28
- if (address2) addresses.push_back (address2);
29
- result.push_back (addresses);
30
- return result;
31
- }
32
-
33
21
UniValue CallRPC (string args)
34
22
{
35
23
vector<string> vArgs;
Original file line number Diff line number Diff line change @@ -243,11 +243,7 @@ BOOST_AUTO_TEST_CASE(util_IsHex)
243
243
244
244
BOOST_AUTO_TEST_CASE (util_seed_insecure_rand)
245
245
{
246
- int i;
247
- int count=0 ;
248
-
249
246
seed_insecure_rand (true );
250
-
251
247
for (int mod=2 ;mod<11 ;mod++)
252
248
{
253
249
int mask = 1 ;
@@ -256,10 +252,9 @@ BOOST_AUTO_TEST_CASE(util_seed_insecure_rand)
256
252
// mask is 2^ceil(log2(mod))-1
257
253
while (mask<mod-1 )mask=(mask<<1 )+1 ;
258
254
259
- count = 0 ;
255
+ int count = 0 ;
260
256
// How often does it get a zero from the uniform range [0,mod)?
261
- for (i=0 ;i<10000 ;i++)
262
- {
257
+ for (int i = 0 ; i < 10000 ; i++) {
263
258
uint32_t rval;
264
259
do {
265
260
rval=insecure_rand ()&mask;
You can’t perform that action at this time.
0 commit comments