coins: Fix GetCoin to not return spent coins in CoinsViewBottom #32231

pull VolodymyrBg wants to merge 1 commits into bitcoin:master from VolodymyrBg:bg changing 1 files +6 −2
  1. VolodymyrBg commented at 5:29 pm on April 7, 2025: none
    This commit modifies the GetCoin method in the CoinsViewBottom test class to not return spent coins. Previously, it would return any coin found in the map, regardless of whether it was spent or not. Now it checks the IsSpent() status before returning and only returns unspent coins, ensuring consistent behavior with other implementations of the CCoinsView interface.
  2. DrahtBot commented at 5:29 pm on April 7, 2025: contributor

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/32231.

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    Concept NACK l0rinc

    If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

  3. DrahtBot added the label UTXO Db and Indexes on Apr 7, 2025
  4. coins: Fix GetCoin to not return spent coins in CoinsViewBottom
    Update coinscache_sim.cpp
    
    coins: Fix GetCoin to not return spent coins in CoinsViewBottom
    5c5817d149
  5. VolodymyrBg force-pushed on Apr 7, 2025
  6. l0rinc commented at 5:35 pm on April 7, 2025: contributor

    NACK, you’ve only changed the fuzz test.

    There’s already an actual fix as well, see: https://github.com/bitcoin/bitcoin/pull/30673/files#diff-f0ed73d62dae6ca28ebd3045e5fc0d5d02eaaacadb4c2a292985a3fbd7e1c77cL54

  7. VolodymyrBg closed this on Apr 7, 2025


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2025-04-16 15:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me