diff options
author | Rider Linden <rider@lindenlab.com> | 2015-05-27 17:15:01 -0700 |
---|---|---|
committer | Rider Linden <rider@lindenlab.com> | 2015-05-27 17:15:01 -0700 |
commit | 83543e556cba8753077c9f004bb0dc71b4509007 (patch) | |
tree | db3a0f30e486475f72ddf945a5a6263b1219a4a0 /indra/llcorehttp/_httpoprequest.cpp | |
parent | 9134a3a097607e427b18af010774eb842be893f2 (diff) |
Memory leak (extra ref) in webprofile
Viewer media routines to coroutine.
Post with raw respons in llcorehttputil
LLCore::Http added headers only option (applies only on get)
Diffstat (limited to 'indra/llcorehttp/_httpoprequest.cpp')
-rwxr-xr-x | indra/llcorehttp/_httpoprequest.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/indra/llcorehttp/_httpoprequest.cpp b/indra/llcorehttp/_httpoprequest.cpp index b1b05dc285..3b6647882e 100755 --- a/indra/llcorehttp/_httpoprequest.cpp +++ b/indra/llcorehttp/_httpoprequest.cpp @@ -532,6 +532,7 @@ HttpStatus HttpOpRequest::prepareRequest(HttpService * service) long sslPeerV(0L); long sslHostV(0L); long dnsCacheTimeout(-1L); + long nobody(0L); if (mReqOptions) { @@ -539,6 +540,7 @@ HttpStatus HttpOpRequest::prepareRequest(HttpService * service) sslPeerV = mReqOptions->getSSLVerifyPeer() ? 1L : 0L; sslHostV = mReqOptions->getSSLVerifyHost() ? 2L : 0L; dnsCacheTimeout = mReqOptions->getDNSCacheTimeout(); + nobody = mReqOptions->getHeadersOnly() ? 1L : 0L; } code = curl_easy_setopt(mCurlHandle, CURLOPT_FOLLOWLOCATION, follow_redirect); check_curl_easy_code(code, CURLOPT_FOLLOWLOCATION); @@ -548,6 +550,9 @@ HttpStatus HttpOpRequest::prepareRequest(HttpService * service) code = curl_easy_setopt(mCurlHandle, CURLOPT_SSL_VERIFYHOST, sslHostV); check_curl_easy_code(code, CURLOPT_SSL_VERIFYHOST); + code = curl_easy_setopt(mCurlHandle, CURLOPT_NOBODY, nobody); + check_curl_easy_code(code, CURLOPT_NOBODY); + // The Linksys WRT54G V5 router has an issue with frequent // DNS lookups from LAN machines. If they happen too often, // like for every HTTP request, the router gets annoyed after @@ -587,7 +592,8 @@ HttpStatus HttpOpRequest::prepareRequest(HttpService * service) switch (mReqMethod) { case HOR_GET: - code = curl_easy_setopt(mCurlHandle, CURLOPT_HTTPGET, 1); + if (nobody == 0) + code = curl_easy_setopt(mCurlHandle, CURLOPT_HTTPGET, 1); check_curl_easy_code(code, CURLOPT_HTTPGET); break; |