diff options
Diffstat (limited to 'src/net/http/header.go')
-rw-r--r-- | src/net/http/header.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/net/http/header.go b/src/net/http/header.go index 153b94370f..d847b13118 100644 --- a/src/net/http/header.go +++ b/src/net/http/header.go @@ -168,6 +168,8 @@ func (h Header) WriteSubset(w io.Writer, exclude map[string]bool) error { // letter and any letter following a hyphen to upper case; // the rest are converted to lowercase. For example, the // canonical key for "accept-encoding" is "Accept-Encoding". +// If s contains a space or invalid header field bytes, it is +// returned without modifications. func CanonicalHeaderKey(s string) string { return textproto.CanonicalMIMEHeaderKey(s) } // hasToken reports whether token appears with v, ASCII |