Welcome to CRUX bug tracking.
FS#815 - core/httpup nocache to avoid stale ports.
|
DetailsI'd like to propose httpup not to use cached results for ports as recent changes can sometimes return stale results, for those behind transparent proxies.
This patch resolves my problems. I have control over 1 transparent proxy that I have here but I also have another transparent proxy in Melbourne that I can not do anything about, other than not use cached files, hence this patch. diff -pruN httpup-0.4.0k.orig/httpup.cpp httpup-0.4.0k/httpup.cpp --- httpup-0.4.0k.orig/httpup.cpp 2012-04-19 12:49:15.722730627 +0000 +++ httpup-0.4.0k/httpup.cpp 2012-04-19 12:53:23.280723487 +0000 @@ -227,7 +227,12 @@ int HttpUp::exec(ExecType type) curl_global_init(CURL_GLOBAL_ALL); curl = curl_easy_init(); + struct curl_slist *headers=NULL; + headers = curl_slist_append(headers, "Cache-Control: no-cache, must-revalidate"); + headers = curl_slist_append(headers, "Pragma: no-cache"); + char errorBuffer[CURL_ERROR_SIZE]; + curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers); curl_easy_setopt(curl, CURLOPT_ERRORBUFFER, errorBuffer); curl_easy_setopt(curl, CURLOPT_FAILONERROR, 1); curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1); |
This task depends upon