mirror of
https://github.com/ZDoom/qzdoom.git
synced 2025-02-27 06:11:46 +00:00
Make global symbols survive GC runs
- The global symbol table was never marked by the GC, so anything pointed only by it was fair game to disappear. - Don't clear the global symbol table during DECORATE parsing. Junk in there should be considered constant after initialization.
This commit is contained in:
parent
61b419c187
commit
6c7788d2ad
2 changed files with 2 additions and 1 deletions
|
@ -370,6 +370,8 @@ static void MarkRoot()
|
||||||
{
|
{
|
||||||
Mark(PClass::AllClasses[i]);
|
Mark(PClass::AllClasses[i]);
|
||||||
}
|
}
|
||||||
|
// Mark global symbols
|
||||||
|
GlobalSymbols.MarkSymbols();
|
||||||
// Mark bot stuff.
|
// Mark bot stuff.
|
||||||
Mark(bglobal.firstthing);
|
Mark(bglobal.firstthing);
|
||||||
Mark(bglobal.body1);
|
Mark(bglobal.body1);
|
||||||
|
|
|
@ -425,7 +425,6 @@ void LoadActors ()
|
||||||
|
|
||||||
timer.Reset(); timer.Clock();
|
timer.Reset(); timer.Clock();
|
||||||
ActorDamageFuncs.Clear();
|
ActorDamageFuncs.Clear();
|
||||||
GlobalSymbols.ReleaseSymbols();
|
|
||||||
FScriptPosition::ResetErrorCounter();
|
FScriptPosition::ResetErrorCounter();
|
||||||
InitThingdef();
|
InitThingdef();
|
||||||
lastlump = 0;
|
lastlump = 0;
|
||||||
|
|
Loading…
Reference in a new issue