From 32895db9d67bffebacdb644b5a5e66b6330230b6 Mon Sep 17 00:00:00 2001 From: Sandeep Mistry Date: Tue, 28 Jun 2016 16:50:33 -0400 Subject: [PATCH] Treat 101 status codes as a complete --- HttpClient.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/HttpClient.cpp b/HttpClient.cpp index 4159b9f..287e8c7 100644 --- a/HttpClient.cpp +++ b/HttpClient.cpp @@ -439,7 +439,7 @@ int HttpClient::responseStatusCode() delay(kHttpWaitForDataDelay); } } - if ( (c == '\n') && (iStatusCode < 200) ) + if ( (c == '\n') && (iStatusCode < 200 && iStatusCode != 101) ) { // We've reached the end of an informational status line c = '\0'; // Clear c so we'll go back into the data reading loop @@ -447,7 +447,7 @@ int HttpClient::responseStatusCode() } // If we've read a status code successfully but it's informational (1xx) // loop back to the start - while ( (iState == eStatusCodeRead) && (iStatusCode < 200) ); + while ( (iState == eStatusCodeRead) && (iStatusCode < 200 && iStatusCode != 101) ); if ( (c == '\n') && (iState == eStatusCodeRead) ) {