Skip to content
Bitcoin Roots

v30.3-roots.1 · Commit 28: [PATCH 28/68] fix(wallet): secure asynchronous sweep cancellation

src/qt/walletmodel.h

Before: src/qt/walletmodel.h · After: src/qt/walletmodel.h

File metadata
index 912c9aab56f1392395355fb7e5954ccdbc0f4175..1d3e531e904d1fc335da00f1380d265024f6add9 100644

Download original patch · Release notes

Diff rows 1–15 of 15. Line numbers refer to the original before/after files.

+ Added− RemovedUnmarked lines are context.

Scroll the code area horizontally to read long lines. Before is on the left; after is on the right. Unified view fits narrow screens more easily.

src/qt/walletmodel.h CHANGED
@@ -158,7 +158,7 @@ public:
158
  // Otherwise, uses the wallet's cached available balance.
159
  CAmount getAvailableBalance(const wallet::CCoinControl* control);
160
 
161
- uint64_t invalidateSweepRequests();
162
  uint64_t requestSweep(SecureString private_key, CTxDestination destination, bool broadcast,
163
  std::optional<Txid> expected_txid = std::nullopt);
164
 
@@ -174,6 +174,7 @@ private:
174
  interfaces::Node& m_node;
175
 
176
  uint64_t m_sweep_request_generation{0};
 
177
  QObject m_sweep_context;
178
  QThread m_sweep_thread;
179
  bool fForceCheckBalanceChanged{false};
 
158
  // Otherwise, uses the wallet's cached available balance.
159
  CAmount getAvailableBalance(const wallet::CCoinControl* control);
160
 
161
+ bool invalidateSweepRequests();
162
  uint64_t requestSweep(SecureString private_key, CTxDestination destination, bool broadcast,
163
  std::optional<Txid> expected_txid = std::nullopt);
164
 
 
174
  interfaces::Node& m_node;
175
 
176
  uint64_t m_sweep_request_generation{0};
177
+ std::shared_ptr<interfaces::SweepAuthorization> m_sweep_authorization;
178
  QObject m_sweep_context;
179
  QThread m_sweep_thread;
180
  bool fForceCheckBalanceChanged{false};