Skip to content

Commit

Permalink
minor comment change
Browse files Browse the repository at this point in the history
  • Loading branch information
dunglas committed Nov 14, 2020
1 parent 33505cb commit c33edb7
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/net/http/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -1107,8 +1107,7 @@ func checkWriteHeaderCode(code int) {
// Issue 22880: require valid WriteHeader status codes.
// For now we only enforce that it's three digits.
// In the future we might block things over 599 (600 and above aren't defined
// at https://httpwg.org/specs/rfc7231.html#status.codes)
// and we might block under 200 (once we have more mature 1xx support).
// at https://httpwg.org/specs/rfc7231.html#status.codes).
// But for now any three digits.
//
// We used to send "HTTP/1.1 000 0" on the wire in responses but there's
Expand Down Expand Up @@ -1152,7 +1151,7 @@ func (w *response) WriteHeader(code int) {
}
checkWriteHeaderCode(code)

// Handle provisional headers, except 100 (continue) which is handled automatically
// Handle informational headers, except 100 (Continue) which is handled automatically
if code > 100 && code < 200 {
writeStatusLine(w.conn.bufw, w.req.ProtoAtLeast(1, 1), code, w.statusBuf[:])
if code == 103 {
Expand Down

0 comments on commit c33edb7

Please sign in to comment.