ipfs / go-bitswap

The golang implementation of the bitswap protocol
MIT License
216 stars 112 forks source link

fix(decision): fix a datarace on disconnect #508

Closed Stebalien closed 3 years ago

Stebalien commented 3 years ago

We need to hold the ledger's lock while reading from it.

Stebalien commented 3 years ago

Unfortunately, there are still some fundamental (logical) races here. But this should be better than it was, and we have other mitigations for those races.

TL;DR: We need to better manage wantlists.