Skip to content
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

mempool/estimatefee: Fix negative index bug #1813

Merged
merged 1 commit into from
Feb 25, 2022

Conversation

kcalvinalvin
Copy link
Collaborator

Fixes a negative index bug that makes the node crash on chain
reorganizations. The bug is detailed in
github.com//issues/1660.

A better design than just skipping the transaction would make
the fee estimator more accurate and that should implemented
at a later date.

Fixes #1660

Fixes a negative index bug that makes the node crash on chain
reorganizations.  The bug is detailed in
github.com/btcsuite/issues/1660.

A better design than just skipping the transaction would make
the fee estimator more accurate and that should implemented
at a later date.
@coveralls
Copy link

coveralls commented Feb 21, 2022

Pull Request Test Coverage Report for Build 1874648433

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.1%) to 79.794%

Totals Coverage Status
Change from base Build 1808348675: 0.1%
Covered Lines: 1240
Relevant Lines: 1554

💛 - Coveralls

Copy link
Member

@Roasbeef Roasbeef left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🍭

Thanks for implementing the suggested fix!

Agree we want another way to do this eventually, but slightly off fee estimations are better than sporadic crashes...

Also would like to follow this up with a repro using the integration test package, but this bug has been lingering too long imo (and we'd likely want to add more fee estimation tests along the way).

@Roasbeef Roasbeef merged commit 0c6dbfc into btcsuite:master Feb 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

fatal error: sync: Unlock of unlocked RWMutex
3 participants