Fix headers announcements edge case #7919

pull sdaftuar wants to merge 1 commits into bitcoin:master from sdaftuar:fix-sendheaders-edge-case changing 1 files +15 −1
  1. sdaftuar commented at 6:26 PM on April 20, 2016: member

    Previously we would assert that if every block in vBlockHashesToAnnounce is in chainActive, then the blocks to be announced must connect. However, there are edge cases where this assumption could be violated (eg using invalidateblock / reconsiderblock), so just check for this case and revert to inv-announcement instead.

    FYI I encountered this bug once while running mempool_packages.py, and was able to reproduce reliably by repeatedly invoking invalidateblock/reconsiderblock on the tip.

    Perhaps we should backport this to 0.12 as well?

  2. Fix headers announcements edge case
    Previously we would assert that if every block in vBlockHashesToAnnounce is in
    chainActive, then the blocks to be announced must connect.  However, there are
    edge cases where this assumption could be violated (eg using invalidateblock /
    reconsiderblock), so just check for this case and revert to inv-announcement
    instead.
    3a99fb2cb1
  3. morcos commented at 6:42 PM on April 20, 2016: member

    utACK

  4. jonasschnelli added the label P2P on Apr 21, 2016
  5. jonasschnelli commented at 7:07 AM on April 21, 2016: contributor

    utACK 3a99fb2cb14955f5e029d315041a093e957e6c3e

  6. sipa commented at 8:54 AM on April 21, 2016: member

    utACK 3a99fb2

  7. TheBlueMatt commented at 6:21 AM on April 22, 2016: member

    utACK 3a99fb2cb14955f5e029d315041a093e957e6c3e

    On April 20, 2016 11:26:28 AM PDT, Suhas Daftuar notifications@github.com wrote:

    Previously we would assert that if every block in vBlockHashesToAnnounce is in chainActive, then the blocks to be announced must connect. However, there are edge cases where this assumption could be violated (eg using invalidateblock / reconsiderblock), so just check for this case and revert to inv-announcement instead.

    FYI I encountered this bug once while running mempool_packages.py, and was able to reproduce reliably by repeatedly invoking invalidateblock/reconsiderblock on the tip.

    Perhaps we should backport this to 0.12 as well? You can view, comment on, or merge this pull request online at:

    #7919

    -- Commit Summary --

    • Fix headers announcements edge case

    -- File Changes --

    M src/main.cpp (16)

    -- Patch Links --

    #7919.patch #7919.diff


    You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: #7919

  8. laanwj added the label Needs backport on Apr 22, 2016
  9. laanwj merged this on Apr 22, 2016
  10. laanwj closed this on Apr 22, 2016

  11. laanwj referenced this in commit 76176823ba on Apr 22, 2016
  12. MarcoFalke referenced this in commit 20a2bd7abe on Apr 25, 2016
  13. MarcoFalke referenced this in commit 43c14acf14 on Apr 27, 2016
  14. MarcoFalke commented at 10:58 AM on June 9, 2016: member

    Backported as part of #7938. Removing label 'Needs backport'.

  15. MarcoFalke removed the label Needs backport on Jun 9, 2016
  16. thokon00 referenced this in commit f4cb7ebdeb on Jun 28, 2016
  17. nomnombtc referenced this in commit e9edf81666 on Nov 12, 2016
  18. nomnombtc referenced this in commit 1e3b7ed3df on Nov 12, 2016
  19. nomnombtc referenced this in commit 8eb18b8bc9 on Nov 13, 2016
  20. sickpig referenced this in commit 4622fcdbed on Nov 14, 2016
  21. MarkLTZ referenced this in commit 3120c258d3 on Apr 27, 2019
  22. 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-14 12:16 UTC

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