-
Notifications
You must be signed in to change notification settings - Fork 37.7k
Fix headers announcements edge case #7919
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
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.
utACK |
utACK 3a99fb2 |
utACK 3a99fb2 |
utACK 3a99fb2 |
utACK 3a99fb2 On April 20, 2016 11:26:28 AM PDT, Suhas Daftuar notifications@github.com wrote:
|
3a99fb2 Fix headers announcements edge case (Suhas Daftuar)
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. Github-Pull: bitcoin#7919 Rebased-From: 3a99fb2
Backported as part of #7938. Removing label 'Needs backport'. |
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. Github-Pull: bitcoin#7919 Rebased-From: 3a99fb2
Previously we would assert that if every block in
vBlockHashesToAnnounce
is inchainActive
, then the blocks to be announced must connect. However, there areedge 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 invokinginvalidateblock
/reconsiderblock
on the tip.Perhaps we should backport this to 0.12 as well?