From 9959068f2064bc67b1f41af0a5b49c1c37ea7003 Mon Sep 17 00:00:00 2001 From: svost Date: Fri, 25 Mar 2016 08:27:05 +0300 Subject: [PATCH] Fix type mismatch --- src/init.cpp | 2 +- src/miner.cpp | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/init.cpp b/src/init.cpp index 55308ea..1e0daaa 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -376,7 +376,7 @@ bool AppInit2() // ********************************************************* Step 2: parameter interactions - nNodeLifespan = (unsigned int)(GetArg("-addrlifespan", 7)); + nNodeLifespan = GetArgUInt("-addrlifespan", 7); fUseFastIndex = GetBoolArg("-fastindex", true); fUseMemoryLog = GetBoolArg("-memorylog", true); diff --git a/src/miner.cpp b/src/miner.cpp index 6057eec..5d01bb2 100644 --- a/src/miner.cpp +++ b/src/miner.cpp @@ -147,18 +147,18 @@ CBlock* CreateNewBlock(CWallet* pwallet, CTransaction *txCoinStake) } // Largest block you're willing to create: - unsigned int nBlockMaxSize = GetArg("-blockmaxsize", MAX_BLOCK_SIZE_GEN/2); + unsigned int nBlockMaxSize = GetArgUInt("-blockmaxsize", MAX_BLOCK_SIZE_GEN/2); // Limit to betweeen 1K and MAX_BLOCK_SIZE-1K for sanity: - nBlockMaxSize = std::max((unsigned int)1000, std::min((unsigned int)(MAX_BLOCK_SIZE-1000), nBlockMaxSize)); + nBlockMaxSize = std::max(1000u, std::min(MAX_BLOCK_SIZE-1000u, nBlockMaxSize)); // How much of the block should be dedicated to high-priority transactions, // included regardless of the fees they pay - unsigned int nBlockPrioritySize = GetArg("-blockprioritysize", 27000); + unsigned int nBlockPrioritySize = GetArgUInt("-blockprioritysize", 27000); nBlockPrioritySize = std::min(nBlockMaxSize, nBlockPrioritySize); // Minimum block size you want to create; block will be filled with free transactions // until there are no more or the block reaches this size: - unsigned int nBlockMinSize = GetArg("-blockminsize", 0); + unsigned int nBlockMinSize = GetArgUInt("-blockminsize", 0); nBlockMinSize = std::min(nBlockMaxSize, nBlockMinSize); // Fee-per-kilobyte amount considered the same as "free" -- 1.7.1