File tree 2 files changed +6
-2
lines changed
2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -40,6 +40,7 @@ void HttpClient::resetState()
40
40
iIsChunked = false ;
41
41
iChunkLength = 0 ;
42
42
iHttpResponseTimeout = kHttpResponseTimeout ;
43
+ iHttpWaitForDataDelay = kHttpWaitForDataDelay ;
43
44
}
44
45
45
46
void HttpClient::stop ()
@@ -473,7 +474,7 @@ int HttpClient::responseStatusCode()
473
474
{
474
475
// We haven't got any data, so let's pause to allow some to
475
476
// arrive
476
- delay (kHttpWaitForDataDelay );
477
+ delay (iHttpWaitForDataDelay );
477
478
}
478
479
}
479
480
if ( (c == ' \n ' ) && (iStatusCode < 200 && iStatusCode != 101 ) )
@@ -522,7 +523,7 @@ int HttpClient::skipResponseHeaders()
522
523
{
523
524
// We haven't got any data, so let's pause to allow some to
524
525
// arrive
525
- delay (kHttpWaitForDataDelay );
526
+ delay (iHttpWaitForDataDelay );
526
527
}
527
528
}
528
529
if (endOfHeadersReached ())
Original file line number Diff line number Diff line change @@ -317,6 +317,8 @@ class HttpClient : public Client
317
317
virtual operator bool () { return bool (iClient); };
318
318
virtual uint32_t httpResponseTimeout () { return iHttpResponseTimeout; };
319
319
virtual void setHttpResponseTimeout (uint32_t timeout) { iHttpResponseTimeout = timeout; };
320
+ virtual uint32_t httpWaitForDataDelay () { return iHttpWaitForDataDelay; };
321
+ virtual void setHttpWaitForDataDelay (uint32_t delay) { iHttpWaitForDataDelay = delay; };
320
322
protected:
321
323
/* * Reset internal state data back to the "just initialised" state
322
324
*/
@@ -384,6 +386,7 @@ class HttpClient : public Client
384
386
// Stores the value of the current chunk length, if present
385
387
int iChunkLength;
386
388
uint32_t iHttpResponseTimeout;
389
+ uint32_t iHttpWaitForDataDelay;
387
390
bool iConnectionClose;
388
391
bool iSendDefaultRequestHeaders;
389
392
String iHeaderLine;
You can’t perform that action at this time.
0 commit comments