mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-05-24 16:59:26 +00:00
billy.SlotSizeFn is a stateful closure that advances an internal counter on each call. Storing it as p.slotter and calling getSlotSize(p.slotter, ...) on every addLocked permanently mutates the closure state. After the first call, all subsequent slot size lookups start from the wrong position and return incorrect sizes. Replace the slotter field with a factory function (newSlotter) that creates a fresh slotter instance on each call to getSlotSize. Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com> |
||
|---|---|---|
| .. | ||
| blobpool.go | ||
| blobpool_test.go | ||
| config.go | ||
| evictheap.go | ||
| evictheap_test.go | ||
| interface.go | ||
| limbo.go | ||
| lookup.go | ||
| metrics.go | ||
| priority.go | ||
| priority_test.go | ||
| slotter.go | ||
| slotter_test.go | ||