Fix RBF checkpoint off-by-one WAL ID issue

This commit is contained in:
Ben Johnson 2020-09-28 14:46:27 -06:00
parent d826cec4b3
commit 3429421148

View file

@ -250,7 +250,7 @@ func (db *DB) checkpoint(exclusive bool, mu sync.Locker) error {
// Loop over pages in the transaction.
for ; walID <= metaWALID; walID++ {
canCheckpoint := exclusive || minActiveWALID == 0 || walID <= minActiveWALID
canCheckpoint := exclusive || minActiveWALID == 0 || walID < minActiveWALID
page, err := readWALPage(segments, walID)
if err != nil {