summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rwxr-xr-xindra/llcorehttp/_httpoprequest.cpp4
-rwxr-xr-xindra/llcorehttp/_httppolicy.cpp12
-rwxr-xr-xindra/llcorehttp/httpcommon.cpp5
3 files changed, 17 insertions, 4 deletions
diff --git a/indra/llcorehttp/_httpoprequest.cpp b/indra/llcorehttp/_httpoprequest.cpp
index bbda0b82fd..fbbb1614fb 100755
--- a/indra/llcorehttp/_httpoprequest.cpp
+++ b/indra/llcorehttp/_httpoprequest.cpp
@@ -626,8 +626,8 @@ HttpStatus HttpOpRequest::prepareRequest(HttpService * service)
// *TODO: Find a better scheme than timeouts to guarantee liveness.
xfer_timeout *= cpolicy.mPipelining;
}
- // *DEBUG: Useful for timeout handling and "[curl:bugs] #1420" tests
- // xfer_timeout = 3L;
+ // *DEBUG: Enable following override for timeout handling and "[curl:bugs] #1420" tests
+ // xfer_timeout = 1L;
code = curl_easy_setopt(mCurlHandle, CURLOPT_TIMEOUT, xfer_timeout);
check_curl_easy_code(code, CURLOPT_TIMEOUT);
code = curl_easy_setopt(mCurlHandle, CURLOPT_CONNECTTIMEOUT, timeout);
diff --git a/indra/llcorehttp/_httppolicy.cpp b/indra/llcorehttp/_httppolicy.cpp
index 09b9206f63..e5d6321401 100755
--- a/indra/llcorehttp/_httppolicy.cpp
+++ b/indra/llcorehttp/_httppolicy.cpp
@@ -414,6 +414,18 @@ bool HttpPolicy::stageAfterCompletion(HttpOpRequest * op)
// Retry or finalize
if (! op->mStatus)
{
+ // *DEBUG: For "[curl:bugs] #1420" tests. This will interfere
+ // with unit tests due to allocation retention by logging code.
+ // But you won't be checking this in enabled.
+#if 0
+ if (op->mStatus == HttpStatus(HttpStatus::EXT_CURL_EASY, CURLE_OPERATION_TIMEDOUT))
+ {
+ LL_WARNS(LOG_CORE) << "HTTP request " << static_cast<HttpHandle>(op)
+ << " timed out."
+ << LL_ENDL;
+ }
+#endif
+
// If this failed, we might want to retry.
if (op->mPolicyRetries < op->mPolicyRetryLimit && op->mStatus.isRetryable())
{
diff --git a/indra/llcorehttp/httpcommon.cpp b/indra/llcorehttp/httpcommon.cpp
index 8714915fa2..7907e958a4 100755
--- a/indra/llcorehttp/httpcommon.cpp
+++ b/indra/llcorehttp/httpcommon.cpp
@@ -254,8 +254,9 @@ bool HttpStatus::isRetryable() const
*this == op_timedout || // Timer expired
*this == post_error || // Transport problem
*this == partial_file || // Data inconsistency in response
- *this == inv_cont_range || // Short data read disagrees with content-range
- *this == inv_status); // Inv status can reflect internal state problem in libcurl
+ // *DEBUG: Comment out 'inv_status' test for [curl:bugs] #1420 testing.
+ *this == inv_status || // Inv status can reflect internal state problem in libcurl
+ *this == inv_cont_range); // Short data read disagrees with content-range
}
} // end namespace LLCore