Add errCorruptedFormat to list of ignored errors for metadata operations. (#4447)

Fixes listing of objects where xl.json is empty or corrupted to skip to the next disk/server (issue 4354).
This commit is contained in:
Frank Wessels 2017-05-31 20:03:32 -07:00 committed by Harshavardhana
parent 5621e6a494
commit 9ba57a8df0

View File

@ -293,7 +293,7 @@ func pickValidXLMeta(metaArr []xlMetaV1, modTime time.Time) (xlMetaV1, error) {
} }
// list of all errors that can be ignored in a metadata operation. // list of all errors that can be ignored in a metadata operation.
var objMetadataOpIgnoredErrs = append(baseIgnoredErrs, errDiskAccessDenied, errVolumeNotFound, errFileNotFound, errFileAccessDenied) var objMetadataOpIgnoredErrs = append(baseIgnoredErrs, errDiskAccessDenied, errVolumeNotFound, errFileNotFound, errFileAccessDenied, errCorruptedFormat)
// readXLMetaParts - returns the XL Metadata Parts from xl.json of one of the disks picked at random. // readXLMetaParts - returns the XL Metadata Parts from xl.json of one of the disks picked at random.
func (xl xlObjects) readXLMetaParts(bucket, object string) (xlMetaParts []objectPartInfo, err error) { func (xl xlObjects) readXLMetaParts(bucket, object string) (xlMetaParts []objectPartInfo, err error) {