mirror of
https://github.com/minio/minio.git
synced 2025-11-20 09:56:07 -05:00
XL: CompleteMultipart should ignore last part is 0bytes. (#1931)
Fixes #1917
This commit is contained in:
@@ -171,11 +171,6 @@ func (m xlMetaV1) ObjectToPartOffset(offset int64) (partIndex int, partOffset in
|
||||
// Seek until object offset maps to a particular part offset.
|
||||
for i, part := range m.Parts {
|
||||
partIndex = i
|
||||
// Last part can be of '0' bytes, treat it specially and
|
||||
// return right here.
|
||||
if part.Size == 0 {
|
||||
return partIndex, partOffset, nil
|
||||
}
|
||||
// Offset is smaller than size we have reached the proper part offset.
|
||||
if partOffset < part.Size {
|
||||
return partIndex, partOffset, nil
|
||||
|
||||
Reference in New Issue
Block a user