aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2019-06-22 17:50:28 +0000
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2019-10-14 11:43:48 +0000
commit4d0aadc0814fb21bff17738c69a1322853b67563 (patch)
tree56a647aa2354ececa66e35eae222189b9e0ca442
parentwallet: remove long payment ID sending support (diff)
downloadmonero-4d0aadc0814fb21bff17738c69a1322853b67563.tar.xz
wallet_rpc_server: don't report integrated addresses for 0 payment ID
These are dummy ones
-rw-r--r--src/wallet/wallet_rpc_server.cpp7
-rwxr-xr-xtests/functional_tests/multisig.py2
2 files changed, 6 insertions, 3 deletions
diff --git a/src/wallet/wallet_rpc_server.cpp b/src/wallet/wallet_rpc_server.cpp
index b52c63d2b..c44be3404 100644
--- a/src/wallet/wallet_rpc_server.cpp
+++ b/src/wallet/wallet_rpc_server.cpp
@@ -1173,8 +1173,11 @@ namespace tools
crypto::hash payment_id;
if(cryptonote::get_encrypted_payment_id_from_tx_extra_nonce(extra_nonce.nonce, payment_id8))
{
- desc.payment_id = epee::string_tools::pod_to_hex(payment_id8);
- has_encrypted_payment_id = true;
+ if (payment_id8 != crypto::null_hash8)
+ {
+ desc.payment_id = epee::string_tools::pod_to_hex(payment_id8);
+ has_encrypted_payment_id = true;
+ }
}
else if (cryptonote::get_payment_id_from_tx_extra_nonce(extra_nonce.nonce, payment_id))
{
diff --git a/tests/functional_tests/multisig.py b/tests/functional_tests/multisig.py
index e0d8b06a4..e4e908aa1 100755
--- a/tests/functional_tests/multisig.py
+++ b/tests/functional_tests/multisig.py
@@ -272,7 +272,7 @@ class MultisigTest():
assert desc.amount_out == desc.amount_in - fee
assert desc.ring_size == 11
assert desc.unlock_time == 0
- assert desc.payment_id == '0000000000000000'
+ assert not 'payment_id' in desc or desc.payment_id in ['', '0000000000000000']
assert desc.change_amount == desc.amount_in - 1000000000000 - fee
assert desc.change_address == self.wallet_address
assert desc.fee == fee