Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--local_ads/statistics.cpp1
-rw-r--r--map/local_ads_manager.cpp1
2 files changed, 2 insertions, 0 deletions
diff --git a/local_ads/statistics.cpp b/local_ads/statistics.cpp
index f60782684c..629c99c4fe 100644
--- a/local_ads/statistics.cpp
+++ b/local_ads/statistics.cpp
@@ -356,6 +356,7 @@ void Statistics::SendToServer()
ASSERT(!bytes.empty(), ());
platform::HttpClient request(url);
+ request.SetTimeout(5); // timeout in seconds
#ifdef DEV_LOCAL_ADS_SERVER
request.LoadHeaders(true);
request.SetRawHeader("Host", "localads-statistics.maps.me");
diff --git a/map/local_ads_manager.cpp b/map/local_ads_manager.cpp
index 970c2f7493..5b6b85b5bb 100644
--- a/map/local_ads_manager.cpp
+++ b/map/local_ads_manager.cpp
@@ -368,6 +368,7 @@ bool LocalAdsManager::DownloadCampaign(MwmSet::MwmId const & mwmId, std::vector<
return false;
platform::HttpClient request(url);
+ request.SetTimeout(5); // timeout in seconds
bool const success = request.RunHttpRequest() && request.ErrorCode() == 200;
if (!success)