[refactor] rename variable to clarify it is unused and cluster count

This commit is contained in:
glozow 2025-12-09 12:22:07 -08:00
parent 91a8e9b549
commit f7be5fb8fc
2 changed files with 4 additions and 4 deletions

View File

@ -663,9 +663,9 @@ RPCHelpMan listunspent()
entry.pushKV("amount", ValueFromAmount(out.txout.nValue));
entry.pushKV("confirmations", out.depth);
if (!out.depth) {
size_t ancestor_count, descendant_count, ancestor_size;
size_t ancestor_count, unused_cluster_count, ancestor_size;
CAmount ancestor_fees;
pwallet->chain().getTransactionAncestry(out.outpoint.hash, ancestor_count, descendant_count, &ancestor_size, &ancestor_fees);
pwallet->chain().getTransactionAncestry(out.outpoint.hash, ancestor_count, unused_cluster_count, &ancestor_size, &ancestor_fees);
if (ancestor_count) {
entry.pushKV("ancestorcount", ancestor_count);
entry.pushKV("ancestorsize", ancestor_size);

View File

@ -405,8 +405,8 @@ CoinsResult AvailableCoins(const CWallet& wallet,
if (wtx.truc_child_in_mempool.has_value()) continue;
// this unconfirmed v3 transaction has a parent: spending would create a third generation
size_t ancestors, descendants;
wallet.chain().getTransactionAncestry(wtx.tx->GetHash(), ancestors, descendants);
size_t ancestors, unused_cluster_count;
wallet.chain().getTransactionAncestry(wtx.tx->GetHash(), ancestors, unused_cluster_count);
if (ancestors > 1) continue;
} else {
if (wtx.tx->version == TRUC_VERSION) continue;