1
Fork 0

request_set_content_length: set Transfer-Encoding

As a fallback for non-seekable streams
This commit is contained in:
Drew DeVault 2023-02-12 13:10:02 +01:00
parent 2ea358ae35
commit 2d643a6be3

View file

@ -100,6 +100,7 @@ fn request_set_content_length(req: *request, body: io::handle) void = {
case let off: io::off =>
yield off;
case io::error =>
header_add(&req.header, "Transfer-Encoding", "chunked");
return;
};
const ln = io::seek(body, 0, io::whence::END)!;