Commit 6e4e2940 authored by Eric Daniels's avatar Eric Daniels Committed by Brad Fitzpatrick

http/internal: document final CRLF behavior on chunkedWriter

Change-Id: I0f76b40dbfda2d382c88aec377db1851c4ac7441

Change-Id: I0f76b40dbfda2d382c88aec377db1851c4ac7441
GitHub-Last-Rev: ab42559278d8cba9e025b431a459d117500a73da
GitHub-Pull-Request: golang/go#26410
Reviewed-on: https://go-review.googlesource.com/124255Reviewed-by: 's avatarBrad Fitzpatrick <bradfitz@golang.org>
parent c2ba0ca8
......@@ -23,7 +23,9 @@ func NewChunkedReader(r io.Reader) io.Reader {
// NewChunkedWriter returns a new chunkedWriter that translates writes into HTTP
// "chunked" format before writing them to w. Closing the returned chunkedWriter
// sends the final 0-length chunk that marks the end of the stream.
// sends the final 0-length chunk that marks the end of the stream but does
// not send the final CRLF that appears after trailers; trailers and the last
// CRLF must be written separately.
//
// NewChunkedWriter is not needed by normal applications. The http
// package adds chunking automatically if handlers don't set a
......
......@@ -171,7 +171,9 @@ func removeChunkExtension(p []byte) ([]byte, error) {
// NewChunkedWriter returns a new chunkedWriter that translates writes into HTTP
// "chunked" format before writing them to w. Closing the returned chunkedWriter
// sends the final 0-length chunk that marks the end of the stream.
// sends the final 0-length chunk that marks the end of the stream but does
// not send the final CRLF that appears after trailers; trailers and the last
// CRLF must be written separately.
//
// NewChunkedWriter is not needed by normal applications. The http
// package adds chunking automatically if handlers don't set a
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment