Only when tailing volume, the zero-ed cookie should skip checking.

This only happens when checkCookie == false and fsync == false.
This commit is contained in:
Chris Lu
2021-08-13 02:09:35 -07:00
parent a8617c1a39
commit 78e8ddf910
6 changed files with 16 additions and 14 deletions

View File

@@ -129,7 +129,7 @@ func TestCompaction(t *testing.T) {
}
func doSomeWritesDeletes(i int, v *Volume, t *testing.T, infos []*needleInfo) {
n := newRandomNeedle(uint64(i))
_, size, _, err := v.writeNeedle2(n, false)
_, size, _, err := v.writeNeedle2(n, true, false)
if err != nil {
t.Fatalf("write file %d: %v", i, err)
}