diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2015-06-26 15:28:57 -0400 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2015-06-26 15:28:57 -0400 |
commit | 8fee1565eb310081a7f3e26237ddd776c5a9aaaa (patch) | |
tree | 82080f6f5f65ff0b0ca80d3a0e595ee97203f6cd /indra/llcommon/llsingleton.h | |
parent | 3f52cefcc4b4cc00caef56a40e0da1ea981a3073 (diff) |
MAINT-5232: Use LLError::Log::demangle() to log LLSingleton classes.
Diffstat (limited to 'indra/llcommon/llsingleton.h')
-rwxr-xr-x | indra/llcommon/llsingleton.h | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/indra/llcommon/llsingleton.h b/indra/llcommon/llsingleton.h index a82101c367..253e0b9a6b 100755 --- a/indra/llcommon/llsingleton.h +++ b/indra/llcommon/llsingleton.h @@ -104,6 +104,7 @@ protected: // delegate LL_WARNS() logging to llsingleton.cpp static void logwarns(const char* p1, const char* p2="", const char* p3="", const char* p4=""); + static std::string demangle(const char* mangled); // obtain canonical ref_ptr_t static ref_ptr_t get_master_refcount(); @@ -337,11 +338,13 @@ public: { case UNINITIALIZED: // should never be uninitialized at this point - logerrs("Uninitialized singleton ", typeid(DERIVED_TYPE).name()); + logerrs("Uninitialized singleton ", + demangle(typeid(DERIVED_TYPE).name()).c_str()); return NULL; case CONSTRUCTING: - logerrs("Tried to access singleton ", typeid(DERIVED_TYPE).name(), + logerrs("Tried to access singleton ", + demangle(typeid(DERIVED_TYPE).name()).c_str(), " from singleton constructor!"); return NULL; @@ -361,7 +364,8 @@ public: break; case DELETED: - logwarns("Trying to access deleted singleton ", typeid(DERIVED_TYPE).name(), + logwarns("Trying to access deleted singleton ", + demangle(typeid(DERIVED_TYPE).name()).c_str(), " -- creating new instance"); SingletonLifetimeManager::construct(); // same as first time construction |