From c33f4239557f9031c3390a4bc38b7b4623c4941d Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Wed, 17 Jul 2019 23:22:01 -0700 Subject: [PATCH] stop early if compaction fails fix https://github.com/chrislusf/seaweedfs/issues/1015 --- weed/storage/volume_read_write.go | 1 + 1 file changed, 1 insertion(+) diff --git a/weed/storage/volume_read_write.go b/weed/storage/volume_read_write.go index 93ce1eab9..fbc818905 100644 --- a/weed/storage/volume_read_write.go +++ b/weed/storage/volume_read_write.go @@ -224,6 +224,7 @@ func ScanVolumeFileFrom(version needle.Version, dataFile *os.File, offset int64, } if err != nil { glog.V(0).Infof("visit needle error: %v", err) + return fmt.Errorf("visit needle error: %v", err) } offset += NeedleHeaderSize + rest glog.V(4).Infof("==> new entry offset %d", offset)