From 70804b73c182ce0dbf21d1e33ac5f720a0ddb5e0 Mon Sep 17 00:00:00 2001 From: chavacava Date: Mon, 11 Apr 2022 19:03:35 +0200 Subject: [PATCH] fix cond expression referring wrong error variable (#1634) --- api-put-object-streaming.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api-put-object-streaming.go b/api-put-object-streaming.go index 55cc4f14f..8ca81edef 100644 --- a/api-put-object-streaming.go +++ b/api-put-object-streaming.go @@ -171,7 +171,7 @@ func (c *Client) putObjectMultipartStreamFromReadAt(ctx context.Context, bucketN } n, rerr := readFull(io.NewSectionReader(reader, readOffset, partSize), partsBuf[w-1][:partSize]) - if rerr != nil && rerr != io.ErrUnexpectedEOF && err != io.EOF { + if rerr != nil && rerr != io.ErrUnexpectedEOF && rerr != io.EOF { uploadedPartsCh <- uploadedPartRes{ Error: rerr, }