From b4b34ff7707bca55dd0ceb1e5fa0a72bc783b169 Mon Sep 17 00:00:00 2001 From: lateminer Date: Sat, 6 Jan 2018 16:44:09 +0300 Subject: [PATCH] Get rid of remaining auto_ptr mentions --- src/miner.cpp | 4 ++-- src/rpc/mining.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/miner.cpp b/src/miner.cpp index 093549eaf..7a856ae29 100644 --- a/src/miner.cpp +++ b/src/miner.cpp @@ -436,7 +436,7 @@ void static BitcoinMiner(const CChainParams& chainparams) unsigned int nTransactionsUpdatedLast = mempool.GetTransactionsUpdated(); CBlockIndex* pindexPrev = chainActive.Tip(); int64_t *nFees; - auto_ptr pblocktemplate(CreateNewBlock(chainparams, coinbaseScript->reserveScript, nFees, false)); + std::unique_ptr pblocktemplate(CreateNewBlock(chainparams, coinbaseScript->reserveScript, nFees, false)); if (!pblocktemplate.get()) { LogPrintf("Error in BitcoinMiner: Keypool ran out, please call keypoolrefill before restarting the mining thread\n"); @@ -646,7 +646,7 @@ void ThreadStakeMiner(CWallet *pwallet, const CChainParams& chainparams) // Create new block // int64_t nFees; - auto_ptr pblocktemplate(CreateNewBlock(chainparams, reservekey.reserveScript, &nFees, true)); + std::unique_ptr pblocktemplate(CreateNewBlock(chainparams, reservekey.reserveScript, &nFees, true)); if (!pblocktemplate.get()) return; diff --git a/src/rpc/mining.cpp b/src/rpc/mining.cpp index 27be0299d..254fbc300 100644 --- a/src/rpc/mining.cpp +++ b/src/rpc/mining.cpp @@ -818,7 +818,7 @@ UniValue checkkernel(const UniValue& params, bool fHelp) pwalletMain->TopUpKeyPool(); CReserveKey pMiningKey(pwalletMain); - auto_ptr pblocktemplate(CreateNewBlock(Params(), pMiningKey.reserveScript, &nFees, true)); + std::unique_ptr pblocktemplate(CreateNewBlock(Params(), pMiningKey.reserveScript, &nFees, true)); if (!pblocktemplate.get()) throw JSONRPCError(RPC_INTERNAL_ERROR, "Couldn't create new block");