- fixed clearing of actorinfo.

It overwrote memory beyond its end.
This commit is contained in:
Christoph Oelckers 2020-10-14 17:04:09 +02:00
parent e4af4f28ce
commit 91fdf160b6
2 changed files with 1 additions and 18 deletions

View file

@ -1036,13 +1036,6 @@ public:
next = nextspritestat[next];
return n;
}
spritetype *Next()
{
int n = next;
next = nextspritestat[next];
return n < 0? nullptr : &sprite[n];
}
};
class SectIterator
@ -1067,13 +1060,6 @@ public:
next = nextspritesect[next];
return n;
}
spritetype *Next()
{
int n = next;
next = nextspritestat[next];
return n < 0? nullptr : &sprite[n];
}
};
#endif // build_h_

View file

@ -3146,10 +3146,7 @@ void ConCompiler::setmusic()
void loadcons()
{
for (int i = 0; i < MAXTILES; i++)
{
memset(&actorinfo[i], 0, sizeof(actorinfo));
}
memset(&actorinfo, 0, sizeof(actorinfo));
ScriptCode.Clear();
labels.Clear();