mirror of
https://github.com/distribution/distribution.git
synced 2025-08-19 23:38:13 +00:00
s3: nit - ignore HeadObjectOutput if it doesn't have ContentLength
This commit is contained in:
parent
b0fc5ddc8b
commit
a8c352063e
@ -733,7 +733,7 @@ func (d *driver) Stat(ctx context.Context, path string) (storagedriver.FileInfo,
|
||||
Bucket: aws.String(d.Bucket),
|
||||
Key: aws.String(d.s3Path(path)),
|
||||
})
|
||||
if err == nil {
|
||||
if err == nil && headResp.ContentLength != nil {
|
||||
if headResp.ContentLength != nil {
|
||||
fi.Size = *headResp.ContentLength
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user