carrot_impl: fix key image scanning in view-only and burned zombie outputs

This commit is contained in:
jeffro256
2025-04-12 14:26:22 -05:00
committed by akildemir
parent fec249d598
commit ce9c845d26
2 changed files with 133 additions and 1 deletions
+6 -1
View File
@@ -2368,7 +2368,7 @@ void wallet2::scan_key_image(const wallet::enote_view_incoming_scan_info_t &enot
{
ki_out = std::nullopt;
if (m_multisig || m_background_syncing) // no spend privkey
if (m_multisig || m_background_syncing || m_watch_only) // no complete spend privkey
return;
// if keys are encrypted, ask for password
@@ -2524,6 +2524,11 @@ void wallet2::process_new_scanned_transaction(
<< print_money(burning_td->amount()) << " in tx " << burning_td->m_txid << ", received output ignored");
continue;
}
else if (burning_td)
{
// This new, better transfer "burns" the other one
set_spent(ot_it->second, height);
}
// update local received money counts
const rct::xmr_amount extra_received_money = enote_scan_info->amount - (burning_td ? burning_td->amount() : 0);