diff --git a/src/rpc/blockchain.cpp b/src/rpc/blockchain.cpp index 5c3890a0c9..d6013a6a4c 100644 --- a/src/rpc/blockchain.cpp +++ b/src/rpc/blockchain.cpp @@ -1632,7 +1632,7 @@ static RPCHelpMan verifychain() }, [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue { - const int check_level(request.params[0].isNull() ? DEFAULT_CHECKLEVEL : request.params[0].get_int()); + const int check_level{request.params[0].isNull() ? DEFAULT_CHECKLEVEL : request.params[0].get_int()}; const int check_depth{request.params[1].isNull() ? DEFAULT_CHECKBLOCKS : request.params[1].get_int()}; const NodeContext& node = EnsureAnyNodeContext(request.context); diff --git a/src/validation.h b/src/validation.h index fd9bf01d89..1644549a3c 100644 --- a/src/validation.h +++ b/src/validation.h @@ -104,7 +104,7 @@ static const int DEFAULT_STOPATHEIGHT = 0; /** Block files containing a block-height within MIN_BLOCKS_TO_KEEP of ActiveChain().Tip() will not be pruned. */ static const unsigned int MIN_BLOCKS_TO_KEEP = 288; static const signed int DEFAULT_CHECKBLOCKS = 6; -static const unsigned int DEFAULT_CHECKLEVEL = 3; +static constexpr int DEFAULT_CHECKLEVEL{3}; // Require that user allocate at least 945 MiB for block & undo files (blk???.dat and rev???.dat) // At 2B MiB per block, 288 blocks = 576 MiB.