mirror of
https://github.com/pgsty/minio.git
synced 2026-07-19 12:10:24 +03:00
validate if cached value is empty before use (#13830)
fixes a crash reproduced while running hadoop tests
```
goroutine 201564 [running]:
github.com/minio/minio/cmd.metaCacheEntries.resolve({0xc0206ab7a0, 0x4, 0xc0015b1908}, 0xc0212a7040)
github.com/minio/minio/cmd/metacache-entries.go:352 +0x58a
```
Bonus: HeadBucket() should always provide content-type
This commit is contained in:
@@ -1131,7 +1131,9 @@ func (z *erasureServerPools) ListObjects(ctx context.Context, bucket, prefix, ma
|
||||
}
|
||||
merged, err := z.listPath(ctx, &opts)
|
||||
if err != nil && err != io.EOF {
|
||||
logger.LogIf(ctx, err)
|
||||
if !isErrBucketNotFound(err) {
|
||||
logger.LogIf(ctx, err)
|
||||
}
|
||||
return loi, err
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user