Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 31127f4

Browse filesBrowse files
author
t-oot
authored
Support for Transfer-Encoding headers that specify "identify" (espressif#5486)
In [HTTPClient](https://github.com/espressif/arduino-esp32/tree/master/libraries/HTTPClient), if the `Transfer-Encoding` header is set to `identity`, an error (Transfer-Encoding not supported) will occur. HTTPClient will consider the request as `identity` if the `Transfer-Encoding` header is not set. But it is also defined a response with `identity` explicitly set in the `Transfer-Encoding` header (ref:[MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Transfer-Encoding)). This pull request will allow the request to be processed normally even when `identity` is explicitly set.
1 parent 4365a45 commit 31127f4
Copy full SHA for 31127f4

File tree

Expand file treeCollapse file tree

1 file changed

+2
-0
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-0
lines changed

‎libraries/HTTPClient/src/HTTPClient.cpp

Copy file name to clipboardExpand all lines: libraries/HTTPClient/src/HTTPClient.cpp
+2Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1264,6 +1264,8 @@ int HTTPClient::handleHeaderResponse()
12641264
log_d("Transfer-Encoding: %s", transferEncoding.c_str());
12651265
if(transferEncoding.equalsIgnoreCase("chunked")) {
12661266
_transferEncoding = HTTPC_TE_CHUNKED;
1267+
} else if(transferEncoding.equalsIgnoreCase("identity")) {
1268+
_transferEncoding = HTTPC_TE_IDENTITY;
12671269
} else {
12681270
return HTTPC_ERROR_ENCODING;
12691271
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.