diff options
author | Andy Pan <panjf2000@gmail.com> | 2020-11-19 17:30:27 +0800 |
---|---|---|
committer | Tobias Klauser <tobias.klauser@gmail.com> | 2021-02-23 10:04:13 +0000 |
commit | a78b0e67211034743a1f03645312aed35e5c5ba2 (patch) | |
tree | 21d35b535da275ff7726dba20379935acf5ce898 /src/internal | |
parent | 08543f071520074854f280ad789cf79c5a00af7d (diff) | |
download | go-a78b0e67211034743a1f03645312aed35e5c5ba2.tar.gz go-a78b0e67211034743a1f03645312aed35e5c5ba2.zip |
internal/poll: fix the verbose condition in splice
Change-Id: I0b433ea1a78632de20ea58c48c9be0f1fb6eb083
Reviewed-on: https://go-review.googlesource.com/c/go/+/271499
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Trust: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
Diffstat (limited to 'src/internal')
-rw-r--r-- | src/internal/poll/splice_linux.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/internal/poll/splice_linux.go b/src/internal/poll/splice_linux.go index 01baf14ed7..968bc44a5f 100644 --- a/src/internal/poll/splice_linux.go +++ b/src/internal/poll/splice_linux.go @@ -52,7 +52,7 @@ func Splice(dst, src *FD, remain int64) (written int64, handled bool, sc string, // If inPipe == 0 && err == nil, src is at EOF, and the // transfer is complete. handled = handled || (err != syscall.EINVAL) - if err != nil || (inPipe == 0 && err == nil) { + if err != nil || inPipe == 0 { break } n, err = splicePump(dst, prfd, inPipe) |