wallet: Ignore MarkConflict if block hash is not known #7491

pull laanwj wants to merge 1 commits into bitcoin:master from laanwj:2016_02_wallet_markconflict_assert changing 1 files +11 −6
  1. laanwj commented at 7:53 PM on February 9, 2016: member

    If number of conflict confirms cannot be determined, this means that the block is still unknown or not yet part of the main chain, for example during a reindex. Do nothing in that case, instead of crash with an assertion failure. (the block will pass by the wallet again eventually, re-marking the transaction as conflict)

    Fixes #7234.

  2. wallet: Ignore MarkConflict if block hash is not known
    If number of conflict confirms cannot be determined, this means
    that the block is still unknown or not yet part of the main chain,
    for example during a reindex. Do nothing in that case,
    instead of crash with an assertion.
    
    Fixes #7234.
    40e7b61835
  3. laanwj added the label Wallet on Feb 9, 2016
  4. sipa commented at 12:38 PM on February 10, 2016: member

    utACK

  5. laanwj added the label Needs backport on Feb 10, 2016
  6. btcdrak commented at 12:57 PM on February 10, 2016: contributor

    utACK

  7. morcos commented at 1:48 PM on February 10, 2016: member

    @sipa Why is it necessary to have the call to MarkConflicted from the fFromLoadWallet code block in the first place? I assume that's the call site that causes this problem?

    OK Thanks for the answer on IRC. It's for backwards compatibility so conflict information is created (to the extent possible) for pre-0.12 wallets.

  8. laanwj commented at 1:51 PM on February 10, 2016: member

    I assume that's the call site that causes this problem?

    Yes (the other callsite should never hit this, as it is called with a block that has just become the new tip).

  9. morcos commented at 5:31 PM on February 10, 2016: member

    utACK

  10. laanwj merged this on Feb 10, 2016
  11. laanwj closed this on Feb 10, 2016

  12. laanwj referenced this in commit c9da9c4bd8 on Feb 10, 2016
  13. laanwj referenced this in commit 00ec73e062 on Feb 10, 2016
  14. laanwj commented at 7:34 PM on February 10, 2016: member

    Cherry-picked to 0.12 as 00ec73e062cac5b23bc99a0010fc9ce6cd20b99e

  15. laanwj removed the label Needs backport on Feb 10, 2016
  16. random-zebra referenced this in commit 8ab63d3e5b on Jul 29, 2020
  17. MarcoFalke locked this on Sep 8, 2021

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: 2026-04-13 15:15 UTC

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