mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-20 15:19:07 +01:00
bitcoin-wallet tool: Drop MakeChain calls
Pass null Chain interface pointer to CWallet. This is needed to drop libbitcoin_server dependency and avoid linking node code.
This commit is contained in:
@@ -29,7 +29,7 @@ static void addCoin(const CAmount& nValue, const CWallet& wallet, std::vector<st
|
||||
static void CoinSelection(benchmark::State& state)
|
||||
{
|
||||
auto chain = interfaces::MakeChain();
|
||||
const CWallet wallet(*chain, WalletLocation(), WalletDatabase::CreateDummy());
|
||||
const CWallet wallet(chain.get(), WalletLocation(), WalletDatabase::CreateDummy());
|
||||
std::vector<std::unique_ptr<CWalletTx>> wtxs;
|
||||
LOCK(wallet.cs_wallet);
|
||||
|
||||
@@ -61,7 +61,7 @@ static void CoinSelection(benchmark::State& state)
|
||||
|
||||
typedef std::set<CInputCoin> CoinSet;
|
||||
static auto testChain = interfaces::MakeChain();
|
||||
static const CWallet testWallet(*testChain, WalletLocation(), WalletDatabase::CreateDummy());
|
||||
static const CWallet testWallet(testChain.get(), WalletLocation(), WalletDatabase::CreateDummy());
|
||||
std::vector<std::unique_ptr<CWalletTx>> wtxn;
|
||||
|
||||
// Copied from src/wallet/test/coinselector_tests.cpp
|
||||
|
||||
Reference in New Issue
Block a user