Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
net/http: make HTTP/1.x handlers able to sent undeclared trailers like HTTP/2 #15754
The HTTP/2 server permits setting Trailers mid-Handler without predeclaring them the "Trailer" header by setting "Trailer:Foo" = "Bar". Since a colon isn't allowed in a trailer, that magic prefix is safe.
Do the same for HTTP/1.x. (and thus also in httptest.ResponseRecorder).