diff options
author | simon <none@none> | 2014-02-21 11:18:12 -0800 |
---|---|---|
committer | simon <none@none> | 2014-02-21 11:18:12 -0800 |
commit | ea944fd58f6fcaf29a939ed10e9fd5e07b9fb923 (patch) | |
tree | d18a3d5fc4f3220fc6d36d24e8cb1b05630e1f9f /indra/llmessage | |
parent | a23fc01c7b12299297124f4b5b6ad4e7a8145c00 (diff) | |
parent | 76913530ed04798536e8469dbeaea9e512d122aa (diff) |
Merge downstream code
Diffstat (limited to 'indra/llmessage')
-rwxr-xr-x | indra/llmessage/llbuffer.cpp | 2 | ||||
-rwxr-xr-x | indra/llmessage/llcachename.cpp | 2 | ||||
-rwxr-xr-x | indra/llmessage/llcurl.cpp | 1 | ||||
-rwxr-xr-x | indra/llmessage/llhttpnode.cpp | 4 | ||||
-rwxr-xr-x | indra/llmessage/llhttpsender.cpp | 3 | ||||
-rwxr-xr-x | indra/llmessage/llhttpsender.h | 2 | ||||
-rwxr-xr-x | indra/llmessage/llmessagetemplate.h | 1 |
7 files changed, 9 insertions, 6 deletions
diff --git a/indra/llmessage/llbuffer.cpp b/indra/llmessage/llbuffer.cpp index 01da20f060..aaa49d2ed6 100755 --- a/indra/llmessage/llbuffer.cpp +++ b/indra/llmessage/llbuffer.cpp @@ -225,7 +225,7 @@ LLBufferArray::LLBufferArray() : LLBufferArray::~LLBufferArray() { std::for_each(mBuffers.begin(), mBuffers.end(), DeletePointer()); - + mBuffers.clear(); delete mMutexp; } diff --git a/indra/llmessage/llcachename.cpp b/indra/llmessage/llcachename.cpp index 267c48e1d2..13d779ff83 100755 --- a/indra/llmessage/llcachename.cpp +++ b/indra/llmessage/llcachename.cpp @@ -278,7 +278,9 @@ LLCacheName::Impl::Impl(LLMessageSystem* msg) LLCacheName::Impl::~Impl() { for_each(mCache.begin(), mCache.end(), DeletePairedPointer()); + mCache.clear(); for_each(mReplyQueue.begin(), mReplyQueue.end(), DeletePointer()); + mReplyQueue.clear(); } boost::signals2::connection LLCacheName::Impl::addPending(const LLUUID& id, const LLCacheNameCallback& callback) diff --git a/indra/llmessage/llcurl.cpp b/indra/llmessage/llcurl.cpp index 081f070866..588e6eea83 100755 --- a/indra/llmessage/llcurl.cpp +++ b/indra/llmessage/llcurl.cpp @@ -1738,6 +1738,7 @@ void LLCurl::cleanupClass() #if SAFE_SSL CRYPTO_set_locking_callback(NULL); for_each(sSSLMutex.begin(), sSSLMutex.end(), DeletePointer()); + sSSLMutex.clear(); #endif LL_CHECK_MEMORY diff --git a/indra/llmessage/llhttpnode.cpp b/indra/llmessage/llhttpnode.cpp index 5c2f73eccb..f6ccb5bdda 100755 --- a/indra/llmessage/llhttpnode.cpp +++ b/indra/llmessage/llhttpnode.cpp @@ -76,8 +76,8 @@ LLHTTPNode::LLHTTPNode() // virtual LLHTTPNode::~LLHTTPNode() { - std::for_each(impl.mNamedChildren.begin(), impl.mNamedChildren.end(), - DeletePairedPointer()); + std::for_each(impl.mNamedChildren.begin(), impl.mNamedChildren.end(), DeletePairedPointer()); + impl.mNamedChildren.clear(); delete impl.mWildcardChild; diff --git a/indra/llmessage/llhttpsender.cpp b/indra/llmessage/llhttpsender.cpp index c48cbc42a6..d0bd343db6 100755 --- a/indra/llmessage/llhttpsender.cpp +++ b/indra/llmessage/llhttpsender.cpp @@ -38,7 +38,7 @@ namespace { typedef std::map<LLHost, LLHTTPSender*> SenderMap; static SenderMap senderMap; - static LLHTTPSender* defaultSender = new LLHTTPSender(); + static LLPointer<LLHTTPSender> defaultSender(new LLHTTPSender()); } //virtual @@ -90,6 +90,5 @@ void LLHTTPSender::clearSender(const LLHost& host) //static void LLHTTPSender::setDefaultSender(LLHTTPSender* sender) { - delete defaultSender; defaultSender = sender; } diff --git a/indra/llmessage/llhttpsender.h b/indra/llmessage/llhttpsender.h index 88920db24d..ff8fa2f95b 100755 --- a/indra/llmessage/llhttpsender.h +++ b/indra/llmessage/llhttpsender.h @@ -32,7 +32,7 @@ class LLHost; class LLSD; -class LLHTTPSender +class LLHTTPSender : public LLThreadSafeRefCount { public: diff --git a/indra/llmessage/llmessagetemplate.h b/indra/llmessage/llmessagetemplate.h index ae8e0087c1..005a49cedf 100755 --- a/indra/llmessage/llmessagetemplate.h +++ b/indra/llmessage/llmessagetemplate.h @@ -118,6 +118,7 @@ public: ~LLMsgData() { for_each(mMemberBlocks.begin(), mMemberBlocks.end(), DeletePairedPointer()); + mMemberBlocks.clear(); } void addBlock(LLMsgBlkData *blockp) |