Repository navigation
fix: never select chunked framing for an HTTP/3 request (stream writer) - #641
Merged
viniciussanchez merged 1 commit intoDec 3, 2026
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fix: never select chunked framing for an HTTP/3 request (stream writer)
Summary
THorseStreamWriterBase.Createinsrc/Horse.Response.paspicks chunkedtransfer-coding for every protocol version except
HTTP/2:A provider whose
RawWebRequest.ProtocolVersionreportsHTTP/3wouldtherefore get
Transfer-Encoding: chunkedon every streamed response. HTTP/3frames the body itself and forbids
Transfer-Encodingentirely (RFC 9114§4.2), exactly as HTTP/2 does (RFC 9113 §8.2.2). This change excludes
HTTP/3the same way
HTTP/2is excluded, and nothing else:Why now
No Horse provider speaks HTTP/3 today. The transport-neutral core is the
reason to fix it ahead of one:
THorseRequestalready treats the WebSocketupgrade signal as protocol-agnostic ("HTTP/3 uses the same extended-CONNECT
mechanism",
Horse.Request.pas), and this is the one remaining place in corewhere a protocol is named rather than a property of it. The change is one
andclause plus a comment; behaviour for every existing provider (HTTP/1.1and HTTP/2) is unchanged.
Tests
No existing test exercises
THorseStreamWriterBaseby protocol version, andno provider can produce
HTTP/3yet, so this PR carries no new test. Theexisting streaming tests (Indy, HTTP.sys, IOCP, epoll, and the hybrid
providers' test 47) cover the unchanged HTTP/1.1 and HTTP/2 branches.