diff options
| author | Oz Linden <oz@lindenlab.com> | 2011-09-14 11:21:53 -0400 | 
|---|---|---|
| committer | Oz Linden <oz@lindenlab.com> | 2011-09-14 11:21:53 -0400 | 
| commit | 11340e3eb3011930f2765d452685632112775cf1 (patch) | |
| tree | d712ccdaa7cf818aaa08defb45d5393fe7d1a0e4 /indra/llmessage | |
| parent | a3e092db14cd0ca785ae46b99f6e275eedc0ddc1 (diff) | |
| parent | 19371a9abed3198f9f6083c3b2483e65778e944a (diff) | |
merge possible fix for storm-1562
Diffstat (limited to 'indra/llmessage')
| -rw-r--r-- | indra/llmessage/llcurl.cpp | 6 | ||||
| -rw-r--r-- | indra/llmessage/llcurl.h | 1 | 
2 files changed, 6 insertions, 1 deletions
diff --git a/indra/llmessage/llcurl.cpp b/indra/llmessage/llcurl.cpp index 14e169c6b1..280a8942a8 100644 --- a/indra/llmessage/llcurl.cpp +++ b/indra/llmessage/llcurl.cpp @@ -222,7 +222,7 @@ namespace boost  std::set<CURL*> LLCurl::Easy::sFreeHandles;  std::set<CURL*> LLCurl::Easy::sActiveHandles;  LLMutex* LLCurl::Easy::sHandleMutex = NULL; - +LLMutex* LLCurl::Easy::sMultiMutex = NULL;  //static  CURL* LLCurl::Easy::allocEasyHandle() @@ -606,6 +606,7 @@ void LLCurl::Multi::run()  		mPerformState = PERFORM_STATE_PERFORMING;  		if (!mQuitting)  		{ +			LLMutexLock lock(LLCurl::Easy::sMultiMutex);  			doPerform();  		}  	} @@ -1179,6 +1180,7 @@ void LLCurl::initClass(bool multi_threaded)  	check_curl_code(code);  	Easy::sHandleMutex = new LLMutex(); +	Easy::sMultiMutex = new LLMutex();  #if SAFE_SSL  	S32 mutex_count = CRYPTO_num_locks(); @@ -1200,6 +1202,8 @@ void LLCurl::cleanupClass()  	delete Easy::sHandleMutex;  	Easy::sHandleMutex = NULL; +	delete Easy::sMultiMutex; +	Easy::sMultiMutex = NULL;  	for (std::set<CURL*>::iterator iter = Easy::sFreeHandles.begin(); iter != Easy::sFreeHandles.end(); ++iter)  	{ diff --git a/indra/llmessage/llcurl.h b/indra/llmessage/llcurl.h index 213b281e72..a876a1562e 100644 --- a/indra/llmessage/llcurl.h +++ b/indra/llmessage/llcurl.h @@ -251,6 +251,7 @@ private:  	static std::set<CURL*> sFreeHandles;  	static std::set<CURL*> sActiveHandles;  	static LLMutex* sHandleMutex; +	static LLMutex* sMultiMutex;  };  class LLCurl::Multi : public LLThread  | 
