aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/wallet2.cpp
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2016-07-23 12:09:33 +0100
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2016-08-28 21:29:43 +0100
commitcf33e1a52a0cf20a7cec619d85d68f000b2e1f40 (patch)
treef8230d6384ea0b6a3422a3f64cbc76880732052e /src/wallet/wallet2.cpp
parentwallet2_api: zero amounts are now allowed with rct (diff)
downloadmonero-cf33e1a52a0cf20a7cec619d85d68f000b2e1f40.tar.xz
rct: do not serialize public keys in outPk
They can be reconstructed from vout
Diffstat (limited to 'src/wallet/wallet2.cpp')
-rw-r--r--src/wallet/wallet2.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/wallet/wallet2.cpp b/src/wallet/wallet2.cpp
index 440aec42c..70f9043f0 100644
--- a/src/wallet/wallet2.cpp
+++ b/src/wallet/wallet2.cpp
@@ -3122,12 +3122,12 @@ static size_t estimate_rct_tx_size(int n_inputs, int mixin, int n_outputs)
size += 32 * n_outputs;
// ecdhInfo
size += 3 * 32 * n_outputs;
- // outPk
- size += 2 * 32 * n_outputs;
+ // outPk - only commitment is saved
+ size += 1 * 32 * n_outputs;
// txnFee
size += 4;
- LOG_PRINT_L2("estimated rct tx size for " << n_inputs << " at mixin " << mixin << " and " << n_outputs << ": " << size << " (" << (32 * n_inputs + 2 * 32 * (mixin+1) * n_inputs) << " saved)");
+ LOG_PRINT_L2("estimated rct tx size for " << n_inputs << " at mixin " << mixin << " and " << n_outputs << ": " << size << " (" << ((32 * n_inputs/*+1*/) + 2 * 32 * (mixin+1) * n_inputs + 32 * n_outputs) << " saved)");
return size;
}