[#131] pool: Remove redundant var from pool.PutObject
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
c8855620b5
commit
32c6e927a0
1 changed files with 1 additions and 3 deletions
|
@ -714,13 +714,11 @@ func (p *pool) PutObject(ctx context.Context, hdr object.Object, payload io.Read
|
|||
buf := make([]byte, sz)
|
||||
|
||||
var n int
|
||||
var ok bool
|
||||
|
||||
for {
|
||||
n, err = payload.Read(buf)
|
||||
if n > 0 {
|
||||
ok = wObj.WritePayloadChunk(buf[:n])
|
||||
if !ok {
|
||||
if !wObj.WritePayloadChunk(buf[:n]) {
|
||||
break
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue