diff options
Diffstat (limited to 'src/rpc/mining.cpp')
-rw-r--r-- | src/rpc/mining.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/rpc/mining.cpp b/src/rpc/mining.cpp index ab9f40d466..3b212dc0e4 100644 --- a/src/rpc/mining.cpp +++ b/src/rpc/mining.cpp @@ -582,7 +582,7 @@ UniValue getblocktemplate(const JSONRPCRequest& request) entry.push_back(Pair("hash", tx.GetWitnessHash().GetHex())); UniValue deps(UniValue::VARR); - BOOST_FOREACH (const CTxIn &in, tx.vin) + for (const CTxIn &in : tx.vin) { if (setTxIndex.count(in.prevout.hash)) deps.push_back(setTxIndex[in.prevout.hash]); @@ -867,10 +867,10 @@ UniValue estimatesmartfee(const JSONRPCRequest& request) } UniValue result(UniValue::VOBJ); - int answerFound; - CFeeRate feeRate = ::feeEstimator.estimateSmartFee(nBlocks, &answerFound, ::mempool, conservative); + FeeCalculation feeCalc; + CFeeRate feeRate = ::feeEstimator.estimateSmartFee(nBlocks, &feeCalc, ::mempool, conservative); result.push_back(Pair("feerate", feeRate == CFeeRate(0) ? -1.0 : ValueFromAmount(feeRate.GetFeePerK()))); - result.push_back(Pair("blocks", answerFound)); + result.push_back(Pair("blocks", feeCalc.returnedTarget)); return result; } |