Commit 334cbe3b authored by Anmol Sethi's avatar Anmol Sethi Committed by Ian Lance Taylor

io: simplified a small part of copyBuffer

Change-Id: I0b7052103174f0864ee9714f76f8f78f2a988777
Reviewed-on: https://go-review.googlesource.com/30719Reviewed-by: 's avatarJoe Tsai <thebrokentoaster@gmail.com>
Run-TryBot: Joe Tsai <thebrokentoaster@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
parent 5f1a013e
......@@ -402,11 +402,10 @@ func copyBuffer(dst Writer, src Reader, buf []byte) (written int64, err error) {
break
}
}
if er == EOF {
break
}
if er != nil {
err = er
if er != EOF {
err = er
}
break
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment