minor
This commit is contained in:
parent
a5360a97eb
commit
8f42a64920
|
@ -321,13 +321,11 @@ func (t *freezerTable) repair() error {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Ensure all reparation changes have been written to disk
|
// Ensure all reparation changes have been written to disk
|
||||||
if !t.readonly {
|
if err := t.index.Sync(); err != nil {
|
||||||
if err := t.index.Sync(); err != nil {
|
return err
|
||||||
return err
|
}
|
||||||
}
|
if err := t.head.Sync(); err != nil {
|
||||||
if err := t.head.Sync(); err != nil {
|
return err
|
||||||
return err
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
// Update the item and byte counters and return
|
// Update the item and byte counters and return
|
||||||
t.items = uint64(t.itemOffset) + uint64(offsetsSize/indexEntrySize-1) // last indexEntry points to the end of the data file
|
t.items = uint64(t.itemOffset) + uint64(offsetsSize/indexEntrySize-1) // last indexEntry points to the end of the data file
|
||||||
|
|
Loading…
Reference in New Issue