aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/wallet.cpp
diff options
context:
space:
mode:
authorAndrew Chow <achow101-github@achow101.com>2019-06-18 15:48:20 -0400
committerAndrew Chow <achow101-github@achow101.com>2019-07-09 16:43:10 -0400
commit33d13edd2bda0af90660e275ea4fa96ca9896f2a (patch)
tree8667304dc05305283b8311575fae897b281e65a9 /src/interfaces/wallet.cpp
parent172213be5b174243dc501c1103ad5fe2fee67a16 (diff)
Replace CReserveKey with ReserveDestinatoin
Instead of reserving keys, reserve destinations which are backed by keys
Diffstat (limited to 'src/interfaces/wallet.cpp')
-rw-r--r--src/interfaces/wallet.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/interfaces/wallet.cpp b/src/interfaces/wallet.cpp
index 93374ea825..4a97ee0c21 100644
--- a/src/interfaces/wallet.cpp
+++ b/src/interfaces/wallet.cpp
@@ -36,7 +36,7 @@ namespace {
class PendingWalletTxImpl : public PendingWalletTx
{
public:
- explicit PendingWalletTxImpl(CWallet& wallet) : m_wallet(wallet), m_key(&wallet) {}
+ explicit PendingWalletTxImpl(CWallet& wallet) : m_wallet(wallet), m_dest(&wallet) {}
const CTransaction& get() override { return *m_tx; }
@@ -47,7 +47,7 @@ public:
auto locked_chain = m_wallet.chain().lock();
LOCK(m_wallet.cs_wallet);
CValidationState state;
- if (!m_wallet.CommitTransaction(m_tx, std::move(value_map), std::move(order_form), m_key, state)) {
+ if (!m_wallet.CommitTransaction(m_tx, std::move(value_map), std::move(order_form), m_dest, state)) {
reject_reason = state.GetRejectReason();
return false;
}
@@ -56,7 +56,7 @@ public:
CTransactionRef m_tx;
CWallet& m_wallet;
- CReserveKey m_key;
+ ReserveDestination m_dest;
};
//! Construct wallet tx struct.
@@ -238,7 +238,7 @@ public:
auto locked_chain = m_wallet->chain().lock();
LOCK(m_wallet->cs_wallet);
auto pending = MakeUnique<PendingWalletTxImpl>(*m_wallet);
- if (!m_wallet->CreateTransaction(*locked_chain, recipients, pending->m_tx, pending->m_key, fee, change_pos,
+ if (!m_wallet->CreateTransaction(*locked_chain, recipients, pending->m_tx, pending->m_dest, fee, change_pos,
fail_reason, coin_control, sign)) {
return {};
}