mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-07-15 05:15:42 +00:00
Separate JS_ShutDown from the normal ScriptingHost shutdown, because it's resetting non-thread-safe per-process state.
DllLoader: Report dlerror when dlopen fails. AtlasObject: Avoid ICC warnings caused by 'const T' being equivalent to 'T' when 'T' is already const. This was SVN commit r5133.
This commit is contained in:
@@ -82,7 +82,13 @@ ScriptingHost::~ScriptingHost()
|
||||
JS_DestroyRuntime(m_RunTime);
|
||||
m_RunTime = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
void ScriptingHost::FinalShutdown()
|
||||
{
|
||||
// This should only be called once per process, just to clean up before
|
||||
// we report memory leaks. (Otherwise, if it's called while there are
|
||||
// other contexts active in other threads, things will break.)
|
||||
JS_ShutDown();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user