Add missing error check in cache GetObjectNInfo (#8889)

master
poornas 5 years ago committed by kannappanr
parent cf37c7997e
commit a78e5d4763
  1. 3
      cmd/disk-cache.go

@ -284,6 +284,9 @@ func (c *cacheObjects) GetObjectNInfo(ctx context.Context, bucket, object string
} }
bkReader, bkErr := c.GetObjectNInfoFn(ctx, bucket, object, rs, h, lockType, opts) bkReader, bkErr := c.GetObjectNInfoFn(ctx, bucket, object, rs, h, lockType, opts)
if bkErr != nil {
return bkReader, bkErr
}
// Record if cache has a hit that was invalidated by ETag verification // Record if cache has a hit that was invalidated by ETag verification
if cacheErr == nil { if cacheErr == nil {
bkReader.ObjInfo.CacheLookupStatus = CacheHit bkReader.ObjInfo.CacheLookupStatus = CacheHit

Loading…
Cancel
Save