Skip to content

Commit

Permalink
Fix max part check (#229)
Browse files Browse the repository at this point in the history
First part is part 1, so 10K parts would be 10001.

Fixes #228
  • Loading branch information
klauspost authored Sep 15, 2022
1 parent df8f2cd commit d691c32
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/bench/multipart.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ func (g *Multipart) InitOnce(ctx context.Context) error {
// and upload a number of objects.
func (g *Multipart) Prepare(ctx context.Context) error {
g.PartStart += g.CreateParts * g.ClientIdx
if g.PartStart+g.CreateParts > 10000 {
if g.PartStart+g.CreateParts > 10001 {
return errors.New("10000 part limit exceeded")
}
console.Println("")
Expand Down

0 comments on commit d691c32

Please sign in to comment.