Commit d2bb8d78 authored by Kirill Smelkov's avatar Kirill Smelkov

X vδT should not keep empty entries

parent e418f9c5
......@@ -1015,14 +1015,20 @@ func xverifyΔBTail_rebuild_TR(t *testing.T, db *zodb.DB, δbtail *ΔBtail, tj *
// verify SliceByRootRev XXX -> verify δbtail.byRoot[treeRoot] directly
// XXX +KVAtTail, +lastRevOf
l := len(vδTok)
vatOK := make([]zodb.Tid, l)
vatOK := []zodb.Tid{}
vδTok_ := []map[Key]Δstring{}
t0 := tj
for i := 0; i<l; i++ {
vatOK[l-i-1] = t0.at
// empty vδTok entries means they should be absent in vδT
if δTok := vδTok[l-i-1]; len(δTok) != 0 {
vatOK = append([]zodb.Tid{t0.at}, vatOK...)
vδTok_ = append([]map[Key]Δstring{δTok}, vδTok_...)
}
t0 = t0.prev
}
vδTok = vδTok_
lo := t0.at
hi := vatOK[l-1]
hi := tj.at
vδToid := δbtail.SliceByRootRev(treeRoot, lo, hi)
l = len(vδToid)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment