SW: Avoid an OOB in GetUpperLowerSector

git-svn-id: https://svn.eduke32.com/eduke32@8302 1a8010ca-5511-0410-912e-c29ae57300e0

# Conflicts:
#	source/sw/src/brooms.cpp
This commit is contained in:
hendricks266 2019-11-26 08:24:33 +00:00 committed by Christoph Oelckers
parent 31f8cb4def
commit 383ecda2b2

View file

@ -830,9 +830,10 @@ GetUpperLowerSector(short match, int x, int y, short *upper, short *lower)
if (!found)
continue;
sectorlist[sln] = i;
if (sln < (int)SIZ(GlobStackSect))
GlobStackSect[sln] = i;
if (sln < (int)SIZ(sectorlist))
sectorlist[sln] = i;
sln++;
}
}