aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/api/transaction_history.cpp
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2016-08-06 19:19:25 +0100
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2016-08-28 21:30:10 +0100
commita47ceee83b0e04a3c440d9ca5a75cf0ac1d9256e (patch)
tree4852efeff376ad287d322d34253967497d923a0b /src/wallet/api/transaction_history.cpp
parentcore: add some locking around pool use (diff)
downloadmonero-a47ceee83b0e04a3c440d9ca5a75cf0ac1d9256e.tar.xz
wallet: do not store signatures in the wallet cache
Saves some substantial space. Also avoid calculating tx hashes we don't need.
Diffstat (limited to '')
-rw-r--r--src/wallet/api/transaction_history.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/wallet/api/transaction_history.cpp b/src/wallet/api/transaction_history.cpp
index db42e2141..95aafb04f 100644
--- a/src/wallet/api/transaction_history.cpp
+++ b/src/wallet/api/transaction_history.cpp
@@ -165,9 +165,8 @@ void TransactionHistoryImpl::refresh()
for (std::list<std::pair<crypto::hash, tools::wallet2::unconfirmed_transfer_details>>::const_iterator i = upayments.begin(); i != upayments.end(); ++i) {
const tools::wallet2::unconfirmed_transfer_details &pd = i->second;
const crypto::hash &hash = i->first;
- uint64_t amount = 0;
- cryptonote::get_inputs_money_amount(pd.m_tx, amount);
- uint64_t fee = amount - get_outs_money_amount(pd.m_tx);
+ uint64_t amount = pd.m_amount_in;
+ uint64_t fee = amount - pd.m_amount_out;
std::string payment_id = string_tools::pod_to_hex(i->second.m_payment_id);
if (payment_id.substr(16).find_first_not_of('0') == std::string::npos)
payment_id = payment_id.substr(0,16);