Clean up LLSingleton work - special case to re-create instance if it's been deleted.

meow-7.2.2
simon 2013-04-25 16:21:32 -07:00
parent 6e483af1f6
commit b49f6e1e74
1 changed files with 3 additions and 1 deletions

View File

@ -145,7 +145,9 @@ public:
if (data.mInitState == DELETED)
{
llwarns << "Trying to access deleted singleton " << typeid(DERIVED_TYPE).name() << " creating new instance" << llendl;
}
data.mSingletonInstance = new DERIVED_TYPE();
data.mInitState = INITIALIZING;
} // Fall into INITIALIZING case below
if (data.mInitState == INITIALIZING)
{