Browse Source

skip file not found error when deleting

pull/2074/head
Chris Lu 4 years ago
parent
commit
1aa7e99a89
  1. 4
      weed/storage/volume_vacuum.go

4
weed/storage/volume_vacuum.go

@ -158,10 +158,10 @@ func (v *Volume) cleanupCompact() error {
e1 := os.Remove(v.FileName(".cpd")) e1 := os.Remove(v.FileName(".cpd"))
e2 := os.Remove(v.FileName(".cpx")) e2 := os.Remove(v.FileName(".cpx"))
if e1 != nil {
if e1 != nil && !os.IsNotExist(e1) {
return e1 return e1
} }
if e2 != nil {
if e2 != nil && !os.IsNotExist(e2) {
return e2 return e2
} }
return nil return nil

Loading…
Cancel
Save