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/http: ServeContent does not send Content-Range in 416 errors #15798

Closed
anacrolix opened this issue May 23, 2016 · 3 comments
Closed

net/http: ServeContent does not send Content-Range in 416 errors #15798

anacrolix opened this issue May 23, 2016 · 3 comments
Labels
FrozenDueToAge help wanted NeedsFix The path to resolution is known, but the work has not been done.
Milestone

Comments

@anacrolix
Copy link
Contributor

https://tools.ietf.org/html/rfc7233#section-4.4 says that if the range cannot be satisfied because it is beyond the length of the instance, Content-Range should be returned with a 416 containing the instance length. This does not occur with http.ServeContent.

@quentinmit quentinmit changed the title http.ServeContent does not send Content-Range in 416 errors net/http: ServeContent does not send Content-Range in 416 errors Jun 17, 2016
@quentinmit quentinmit added the NeedsFix The path to resolution is known, but the work has not been done. label Jun 17, 2016
@quentinmit quentinmit added this to the Go1.8 milestone Jun 17, 2016
@quentinmit
Copy link
Contributor

/cc @bradfitz @adg

With anything HTTP... I defer to the experts to decide if we should follow the spec.

@adg
Copy link
Contributor

adg commented Jun 17, 2016

Sure, seems like a failure mode we overlooked in the implementation. Also seems like low hanging fruit for anyone looking for something to do.

@gopherbot
Copy link

CL https://golang.org/cl/24212 mentions this issue.

@golang golang locked and limited conversation to collaborators Aug 25, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge help wanted NeedsFix The path to resolution is known, but the work has not been done.
Projects
None yet
Development

No branches or pull requests

4 participants