mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2025-01-08 12:01:20 +00:00
e3: close files (#912)
This commit is contained in:
parent
18a0f2bafa
commit
5edc0612ce
@ -66,17 +66,16 @@ func NewLocalityIndex(
|
||||
return li, nil
|
||||
}
|
||||
func (li *LocalityIndex) closeWhatNotInList(fNames []string) {
|
||||
if li == nil || li.file == nil || li.file.decompressor == nil {
|
||||
if li == nil || li.bm == nil {
|
||||
return
|
||||
}
|
||||
|
||||
for _, protectName := range fNames {
|
||||
if li.file.decompressor.FileName() == protectName {
|
||||
continue
|
||||
if li.bm.FileName() == protectName {
|
||||
return
|
||||
}
|
||||
}
|
||||
li.closeFiles()
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
func (li *LocalityIndex) OpenList(fNames []string) error {
|
||||
|
Loading…
Reference in New Issue
Block a user