Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

net: io.CopyN fails to copy from file to net.Conn on Windows [1.10 backport] #27419

FiloSottile opened this issue Aug 31, 2018 · 2 comments


Copy link

@FiloSottile FiloSottile commented Aug 31, 2018

@rasky requested issue #25722 to be considered for backport to the next 1.10 minor release.

It's broken on Windows 10 and workarounds are difficult if the CopyN call happens deep into some networking library.

Copy link

@gopherbot gopherbot commented Nov 1, 2018

Change mentions this issue: [release-branch.go1.10] internal/poll: advance file position in windows sendfile

gopherbot pushed a commit that referenced this issue Nov 1, 2018
…ws sendfile

Some versions of Windows (Windows 10 1803) do not set file
position after TransmitFile completes. So just use Seek
to set file position before returning from sendfile.

Updates #25722
Fixes #27419

Change-Id: I7a49be10304b5db19dda707b13ac93d338aeb190
Reviewed-by: Brad Fitzpatrick <>
Reviewed-by: Ian Lance Taylor <>
Reviewed-by: Yasuhiro MATSUMOTO <>
Run-TryBot: Brad Fitzpatrick <>
TryBot-Result: Gobot Gobot <>
(cherry picked from commit 8359b5e)
Run-TryBot: Ian Lance Taylor <>
Copy link

@gopherbot gopherbot commented Nov 1, 2018

Closed by merging 13a2f53 to release-branch.go1.10.

@gopherbot gopherbot closed this Nov 1, 2018
@golang golang locked and limited conversation to collaborators Nov 1, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants