mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 03:33:48 +00:00
Fixed a leak with console stack in the interpreter.
Issue was pushing a new frame in the global scope. Everytime a global scope was called, 1 ConsoleValue got allocated that was never freed. After 4096 'global scope' function calls, the engine would blow. Also cleans up an extra rogue usage of push/pop with the saver helper.
This commit is contained in:
parent
05a8a014b8
commit
7ac62f42a3
2 changed files with 2 additions and 3 deletions
|
|
@ -1628,9 +1628,9 @@ static ConsoleValue _internalExecute(SimObject *object, S32 argc, ConsoleValue a
|
|||
ICallMethod *com = dynamic_cast<ICallMethod *>(object);
|
||||
if(com)
|
||||
{
|
||||
gCallStack.pushFrame(0);
|
||||
ConsoleStackFrameSaver saver;
|
||||
saver.save();
|
||||
com->callMethodArgList(argc, argv, false);
|
||||
gCallStack.popFrame();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue