From 57c768aa4b5f6be1cabd8cbd49c441eb8fa7d6a3 Mon Sep 17 00:00:00 2001 From: Pablo Rodiz Obaya Date: Thu, 19 May 2016 21:20:44 +0200 Subject: [PATCH] Reduce wait for data delay Waiting for 1 second when no data is available for reading is too much and makes the communication very slow. I have reduced it to 20 miliseconds. --- HttpClient.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/HttpClient.h b/HttpClient.h index 801ccb2..8473bf0 100644 --- a/HttpClient.h +++ b/HttpClient.h @@ -424,7 +424,7 @@ class HttpClient : public Client // Number of milliseconds that we wait each time there isn't any data // available to be read (during status code and header processing) - static const int kHttpWaitForDataDelay = 1000; + static const int kHttpWaitForDataDelay = 20; // Number of milliseconds that we'll wait in total without receiveing any // data before returning HTTP_ERROR_TIMED_OUT (during status code and header // processing)