summaryrefslogtreecommitdiff
path: root/indra/llplugin
diff options
context:
space:
mode:
authorAura Linden <aura@lindenlab.com>2014-06-18 11:32:53 -0700
committerAura Linden <aura@lindenlab.com>2014-06-18 11:32:53 -0700
commita4d60d6721c62511ba7a26352e3b5d35cd0dbb94 (patch)
tree082fa1927273936fa07b9b500a7a3548833cbb6f /indra/llplugin
parent4bcf2079f15a09d40f1d7aa61b2768cc54dc427a (diff)
parent977476171ddcc057d7c28b6c14ae988b8189ed75 (diff)
Pulled merge from release.
Diffstat (limited to 'indra/llplugin')
-rwxr-xr-xindra/llplugin/llplugincookiestore.cpp9
-rwxr-xr-xindra/llplugin/llpluginprocessparent.cpp4
2 files changed, 7 insertions, 6 deletions
diff --git a/indra/llplugin/llplugincookiestore.cpp b/indra/llplugin/llplugincookiestore.cpp
index f64b264222..a5d717389d 100755
--- a/indra/llplugin/llplugincookiestore.cpp
+++ b/indra/llplugin/llplugincookiestore.cpp
@@ -27,6 +27,7 @@
*/
#include "linden_common.h"
+#include "llstl.h"
#include "indra_constants.h"
#include "llplugincookiestore.h"
@@ -654,12 +655,8 @@ void LLPluginCookieStore::setOneCookie(const std::string &s, std::string::size_t
void LLPluginCookieStore::clearCookies()
{
- while(!mCookies.empty())
- {
- cookie_map_t::iterator iter = mCookies.begin();
- delete iter->second;
- mCookies.erase(iter);
- }
+ std::for_each(mCookies.begin(), mCookies.end(), DeletePairedPointer());
+ mCookies.clear();
}
void LLPluginCookieStore::removeCookie(const std::string &key)
diff --git a/indra/llplugin/llpluginprocessparent.cpp b/indra/llplugin/llpluginprocessparent.cpp
index ea0d2b81f1..b5a2588e1e 100755
--- a/indra/llplugin/llpluginprocessparent.cpp
+++ b/indra/llplugin/llpluginprocessparent.cpp
@@ -131,6 +131,8 @@ LLPluginProcessParent::~LLPluginProcessParent()
{
// destroy the shared memory region
iter->second->destroy();
+ delete iter->second;
+ iter->second = NULL;
// and remove it from our map
mSharedMemoryRegions.erase(iter);
@@ -960,6 +962,8 @@ void LLPluginProcessParent::receiveMessage(const LLPluginMessage &message)
{
// destroy the shared memory region
iter->second->destroy();
+ delete iter->second;
+ iter->second = NULL;
// and remove it from our map
mSharedMemoryRegions.erase(iter);