Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
eth/protocols/snap: fix batch writer when resuming an aborted sync (#22)
### Description upstream PR: [go-ethereum#27842](ethereum/go-ethereum#27842) Fixes ethereum/go-ethereum#27813. The closure caused all subtasks to reference the same one batch when writing, so instead of each subtask of a contract growing and flushing it's own batch, they all grew the last one's, but flushed their own. Interestingly however, this should only be an issue if there's also a lack of peers, otherwise whenever a delivery into the last batch is made, it should have flushed out everyone else's data too.
- Loading branch information