cmd/geth, core/rawdb: add missing error checks (#19871)
* Added missing error checks Add error handling where we assign err a value, but don't check for it being nil. * core/rawdb: tiny style nit
This commit is contained in:
committed by
Péter Szilágyi
parent
cc3ef1e4f4
commit
57fc1d21e1
@ -272,7 +272,9 @@ func (t *freezerTable) repair() error {
|
||||
if newLastIndex.filenum != lastIndex.filenum {
|
||||
// Release earlier opened file
|
||||
t.releaseFile(lastIndex.filenum)
|
||||
t.head, err = t.openFile(newLastIndex.filenum, openFreezerFileForAppend)
|
||||
if t.head, err = t.openFile(newLastIndex.filenum, openFreezerFileForAppend); err != nil {
|
||||
return err
|
||||
}
|
||||
if stat, err = t.head.Stat(); err != nil {
|
||||
// TODO, anything more we can do here?
|
||||
// A data file has gone missing...
|
||||
|
Reference in New Issue
Block a user