mirror of
https://github.com/wownero/wownero.git
synced 2026-10-29 04:18:59 +01:00
wallet: derive encrypted payment ID dummy/real status from tx.extra, not cd.dests
This commit is contained in:
@@ -7477,6 +7477,8 @@ bool simple_wallet::accept_loaded_tx(const std::function<size_t()> get_num_txes,
|
||||
if (e.is_integrated)
|
||||
is_dummy = false;
|
||||
|
||||
CHECK_AND_ASSERT_MES(is_dummy == (payment_id8 == crypto::null_hash8), false, "Bad loaded tx: mismatched payment ID info");
|
||||
|
||||
if (is_dummy)
|
||||
{
|
||||
payment_id_string += std::string("dummy encrypted payment ID");
|
||||
@@ -7508,7 +7510,7 @@ bool simple_wallet::accept_loaded_tx(const std::function<size_t()> get_num_txes,
|
||||
{
|
||||
const tx_destination_entry &entry = cd.splitted_dsts[d];
|
||||
std::string address, standard_address = get_account_address_as_str(m_wallet->nettype(), entry.is_subaddress, entry.addr);
|
||||
if (has_encrypted_payment_id && !entry.is_subaddress && standard_address != entry.original)
|
||||
if (has_encrypted_payment_id && !entry.is_subaddress)
|
||||
{
|
||||
address = get_account_integrated_address_as_str(m_wallet->nettype(), entry.addr, payment_id8);
|
||||
address += std::string(" (" + standard_address + " with encrypted payment id " + epee::string_tools::pod_to_hex(payment_id8) + ")");
|
||||
|
||||
Reference in New Issue
Block a user