Skip to content

Commit b640044

Browse files
committed
Merge pull request esp8266#1333 from Links2004/httpClient
HTTPclient - add CHUNKED encoding support
2 parents 92cea85 + 1ab74c1 commit b640044

File tree

7 files changed

+314
-74
lines changed

7 files changed

+314
-74
lines changed

libraries/ESP8266HTTPClient/examples/Authorization/Authorization.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ void loop() {
6363
int httpCode = http.GET();
6464

6565
// httpCode will be negative on error
66-
if(httpCode) {
66+
if(httpCode > 0) {
6767
// HTTP header has been send and Server response header has been handled
6868
USE_SERIAL.printf("[HTTP] GET... code: %d\n", httpCode);
6969

libraries/ESP8266HTTPClient/examples/BasicHttpClient/BasicHttpClient.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ void loop() {
5151
int httpCode = http.GET();
5252

5353
// httpCode will be negative on error
54-
if(httpCode) {
54+
if(httpCode > 0) {
5555
// HTTP header has been send and Server response header has been handled
5656
USE_SERIAL.printf("[HTTP] GET... code: %d\n", httpCode);
5757

libraries/ESP8266HTTPClient/examples/ReuseConnection/ReuseConnection.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ void loop() {
4848
//http.begin("192.168.1.12", 80, "/test.html");
4949

5050
int httpCode = http.GET();
51-
if(httpCode) {
51+
if(httpCode > 0) {
5252
USE_SERIAL.printf("[HTTP] GET... code: %d\n", httpCode);
5353

5454
// file found at server

libraries/ESP8266HTTPClient/examples/StreamHttpClient/StreamHttpClient.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ void loop() {
5050
USE_SERIAL.print("[HTTP] GET...\n");
5151
// start connection and send HTTP header
5252
int httpCode = http.GET();
53-
if(httpCode) {
53+
if(httpCode > 0) {
5454
// HTTP header has been send and Server response header has been handled
5555
USE_SERIAL.printf("[HTTP] GET... code: %d\n", httpCode);
5656

0 commit comments

Comments
 (0)