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

Change "HTTP/3" to "HTTP/3.0". #3439

Merged
merged 1 commit into from Jun 2, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion http3/client.go
Expand Up @@ -330,7 +330,7 @@ func (c *client) doRequest(req *http.Request, str quic.Stream, opt RoundTripOpt,

connState := qtls.ToTLSConnectionState(c.conn.ConnectionState().TLS)
res := &http.Response{
Proto: "HTTP/3",
Proto: "HTTP/3.0",
ProtoMajor: 3,
Header: http.Header{},
TLS: &connState,
Expand Down
2 changes: 1 addition & 1 deletion http3/client_test.go
Expand Up @@ -742,7 +742,7 @@ var _ = Describe("Client", func() {
str.EXPECT().Read(gomock.Any()).DoAndReturn(rspBuf.Read).AnyTimes()
rsp, err := client.RoundTripOpt(req, RoundTripOpt{})
Expect(err).ToNot(HaveOccurred())
Expect(rsp.Proto).To(Equal("HTTP/3"))
Expect(rsp.Proto).To(Equal("HTTP/3.0"))
Expect(rsp.ProtoMajor).To(Equal(3))
Expect(rsp.StatusCode).To(Equal(418))
})
Expand Down
2 changes: 1 addition & 1 deletion http3/request.go
Expand Up @@ -74,7 +74,7 @@ func requestFromHeaders(headers []qpack.HeaderField) (*http.Request, error) {
u.Host = authority
requestURI = authority
} else {
protocol = "HTTP/3"
protocol = "HTTP/3.0"
u, err = url.ParseRequestURI(path)
if err != nil {
return nil, err
Expand Down
2 changes: 1 addition & 1 deletion http3/request_test.go
Expand Up @@ -22,7 +22,7 @@ var _ = Describe("Request", func() {
Expect(req.Method).To(Equal("GET"))
Expect(req.URL.Path).To(Equal("/foo"))
Expect(req.URL.Host).To(BeEmpty())
Expect(req.Proto).To(Equal("HTTP/3"))
Expect(req.Proto).To(Equal("HTTP/3.0"))
Expect(req.ProtoMajor).To(Equal(3))
Expect(req.ProtoMinor).To(BeZero())
Expect(req.ContentLength).To(Equal(int64(42)))
Expand Down