From 2dcbbf04c9375e2de877956476e0a58219a169cf Mon Sep 17 00:00:00 2001 From: "Graham Madarasz (Graham)" Date: Thu, 28 Feb 2013 09:45:43 -0800 Subject: Improve curl/ares init behavior by duping handles instead of calling easy_init --- indra/llmessage/llcurl.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'indra/llmessage/llcurl.h') diff --git a/indra/llmessage/llcurl.h b/indra/llmessage/llcurl.h index 7bcf61e233..a03333157c 100644 --- a/indra/llmessage/llcurl.h +++ b/indra/llmessage/llcurl.h @@ -45,7 +45,7 @@ #include "llqueuedthread.h" #include "llframetimer.h" #include "llpointer.h" - +#include "llsingleton.h" class LLMutex; class LLCurlThread; @@ -53,6 +53,14 @@ class LLCurlThread; // For whatever reason, this is not typedef'd in curl.h typedef size_t (*curl_header_callback)(void *ptr, size_t size, size_t nmemb, void *stream); +class LLCurlHandleHandler : public LLSingleton +{ +public: + static CURL* the_one_true_curl_handle; + LLCurlHandleHandler(); + static CURL* CreateCurlHandle(); +}; + class LLCurl { LOG_CLASS(LLCurl); -- cgit v1.2.3 From 6e483af1f6b7a6f8d0f83e54d79a941607760f7b Mon Sep 17 00:00:00 2001 From: simon Date: Thu, 25 Apr 2013 14:14:35 -0700 Subject: Revert ares and libcurl version update that was causing problems, revise curl handle duplication code. Reviewed by Kelly --- indra/llmessage/llcurl.h | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'indra/llmessage/llcurl.h') diff --git a/indra/llmessage/llcurl.h b/indra/llmessage/llcurl.h index a03333157c..90b3f2815d 100644 --- a/indra/llmessage/llcurl.h +++ b/indra/llmessage/llcurl.h @@ -53,14 +53,6 @@ class LLCurlThread; // For whatever reason, this is not typedef'd in curl.h typedef size_t (*curl_header_callback)(void *ptr, size_t size, size_t nmemb, void *stream); -class LLCurlHandleHandler : public LLSingleton -{ -public: - static CURL* the_one_true_curl_handle; - LLCurlHandleHandler(); - static CURL* CreateCurlHandle(); -}; - class LLCurl { LOG_CLASS(LLCurl); @@ -196,6 +188,8 @@ public: static CURL* newEasyHandle() ; static void deleteEasyHandle(CURL* handle) ; + static CURL* createStandardCurlHandle(); + private: static std::string sCAPath; static std::string sCAFile; @@ -205,6 +199,7 @@ private: static LLMutex* sHandleMutexp ; static S32 sTotalHandles ; static S32 sMaxHandles; + static CURL* sCurlTemplateStandardHandle; public: static bool sNotQuitting; static F32 sCurlRequestTimeOut; -- cgit v1.2.3