File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -40,6 +40,7 @@ void HttpClient::resetState()
4040 iIsChunked = false ;
4141 iChunkLength = 0 ;
4242 iHttpResponseTimeout = kHttpResponseTimeout ;
43+ iHttpWaitForDataDelay = kHttpWaitForDataDelay ;
4344}
4445
4546void HttpClient::stop ()
@@ -473,7 +474,7 @@ int HttpClient::responseStatusCode()
473474 {
474475 // We haven't got any data, so let's pause to allow some to
475476 // arrive
476- delay (kHttpWaitForDataDelay );
477+ delay (iHttpWaitForDataDelay );
477478 }
478479 }
479480 if ( (c == ' \n ' ) && (iStatusCode < 200 && iStatusCode != 101 ) )
@@ -522,7 +523,7 @@ int HttpClient::skipResponseHeaders()
522523 {
523524 // We haven't got any data, so let's pause to allow some to
524525 // arrive
525- delay (kHttpWaitForDataDelay );
526+ delay (iHttpWaitForDataDelay );
526527 }
527528 }
528529 if (endOfHeadersReached ())
Original file line number Diff line number Diff line change @@ -317,6 +317,8 @@ class HttpClient : public Client
317317 virtual operator bool () { return bool (iClient); };
318318 virtual uint32_t httpResponseTimeout () { return iHttpResponseTimeout; };
319319 virtual void setHttpResponseTimeout (uint32_t timeout) { iHttpResponseTimeout = timeout; };
320+ virtual uint32_t httpWaitForDataDelay () { return iHttpWaitForDataDelay; };
321+ virtual void setHttpWaitForDataDelay (uint32_t delay) { iHttpWaitForDataDelay = delay; };
320322protected:
321323 /* * Reset internal state data back to the "just initialised" state
322324 */
@@ -384,6 +386,7 @@ class HttpClient : public Client
384386 // Stores the value of the current chunk length, if present
385387 int iChunkLength;
386388 uint32_t iHttpResponseTimeout;
389+ uint32_t iHttpWaitForDataDelay;
387390 bool iConnectionClose;
388391 bool iSendDefaultRequestHeaders;
389392 String iHeaderLine;
You can’t perform that action at this time.
0 commit comments