diff options
-rw-r--r-- | indra/llmessage/llcoproceduremanager.cpp | 13 | ||||
-rw-r--r-- | indra/llmessage/llcoproceduremanager.h | 1 | ||||
-rw-r--r-- | indra/llmessage/tests/llcoproceduremanager_test.cpp | 5 |
3 files changed, 15 insertions, 4 deletions
diff --git a/indra/llmessage/llcoproceduremanager.cpp b/indra/llmessage/llcoproceduremanager.cpp index 712cab5b19..c1e53ea278 100644 --- a/indra/llmessage/llcoproceduremanager.cpp +++ b/indra/llmessage/llcoproceduremanager.cpp @@ -134,10 +134,7 @@ LLCoprocedureManager::LLCoprocedureManager() LLCoprocedureManager::~LLCoprocedureManager() { - for(auto & poolEntry : mPoolMap) - { - poolEntry.second->close(); - } + close(); } LLCoprocedureManager::poolPtr_t LLCoprocedureManager::initializePool(const std::string &poolName) @@ -255,6 +252,14 @@ size_t LLCoprocedureManager::count(const std::string &pool) const return it->second->count(); } +void LLCoprocedureManager::close() +{ + for(auto & poolEntry : mPoolMap) + { + poolEntry.second->close(); + } +} + void LLCoprocedureManager::close(const std::string &pool) { poolMap_t::iterator it = mPoolMap.find(pool); diff --git a/indra/llmessage/llcoproceduremanager.h b/indra/llmessage/llcoproceduremanager.h index c9b853fc4c..70204ba02b 100644 --- a/indra/llmessage/llcoproceduremanager.h +++ b/indra/llmessage/llcoproceduremanager.h @@ -77,6 +77,7 @@ public: size_t count() const; size_t count(const std::string &pool) const; + void close(); void close(const std::string &pool); private: diff --git a/indra/llmessage/tests/llcoproceduremanager_test.cpp b/indra/llmessage/tests/llcoproceduremanager_test.cpp index 734b986f80..9db13a37b5 100644 --- a/indra/llmessage/tests/llcoproceduremanager_test.cpp +++ b/indra/llmessage/tests/llcoproceduremanager_test.cpp @@ -75,6 +75,11 @@ namespace tut coproceduremanager_test() { } + + ~coproceduremanager_test() + { + LLCoprocedureManager::instance().close(); + } }; typedef test_group<coproceduremanager_test> coproceduremanager_t; typedef coproceduremanager_t::object coproceduremanager_object_t; |