Fixed bug when running two console commands

This was SVN commit r5269.
This commit is contained in:
Ykkrosh 2007-07-24 18:04:38 +00:00
parent 0d019535f2
commit 825eaa5aa3

View File

@ -701,7 +701,7 @@ void CConsole::ProcessBuffer(const wchar_t* szLine)
}
}
JS_SetParent(g_ScriptingHost.GetContext(), m_ScriptObject, NULL); // so the previous one can get garbage-collected
JS_SetParent(g_ScriptingHost.GetContext(), m_ScriptObject, JS_GetGlobalObject(g_ScriptingHost.GetContext())); // so the previous parent can get garbage-collected
}
else
{