aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJaquee <jaquee.monero@gmail.com>2017-08-04 23:20:59 +0200
committerJaquee <jaquee.monero@gmail.com>2017-08-05 19:21:23 +0200
commit48c0cb1ba6b231205c2660bdcb5911fab6328c68 (patch)
tree9b5f5c269d6df7eb2bab5de5c14a5f6ec961ffa2
parentCMakeLists.txt - ios/xcode fix (diff)
downloadmonero-48c0cb1ba6b231205c2660bdcb5911fab6328c68.tar.xz
wallet api: pause refresh while commiting tx
-rw-r--r--src/wallet/api/pending_transaction.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/wallet/api/pending_transaction.cpp b/src/wallet/api/pending_transaction.cpp
index 9798d66c6..c98a599e7 100644
--- a/src/wallet/api/pending_transaction.cpp
+++ b/src/wallet/api/pending_transaction.cpp
@@ -102,6 +102,7 @@ bool PendingTransactionImpl::commit(const std::string &filename, bool overwrite)
}
// Commit tx
else {
+ m_wallet.pauseRefresh();
while (!m_pending_tx.empty()) {
auto & ptx = m_pending_tx.back();
m_wallet.m_wallet->commit_tx(ptx);
@@ -133,6 +134,7 @@ bool PendingTransactionImpl::commit(const std::string &filename, bool overwrite)
m_status = Status_Error;
}
+ m_wallet.startRefresh();
return m_status == Status_Ok;
}