polymer.c: fix out-of-bounds picanm[] read.

git-svn-id: https://svn.eduke32.com/eduke32@2167 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
helixhorned 2011-12-09 19:10:51 +00:00
parent eb764b3b75
commit b85b4d7b7c

View file

@ -2747,7 +2747,7 @@ static void polymer_updatewall(int16_t wallnum)
wallpicnum = wal->picnum; wallpicnum = wal->picnum;
if (picanm[wallpicnum]&192) wallpicnum += animateoffs(wallpicnum,wallnum+16384); if (picanm[wallpicnum]&192) wallpicnum += animateoffs(wallpicnum,wallnum+16384);
walloverpicnum = wal->overpicnum; walloverpicnum = wal->overpicnum;
if (picanm[walloverpicnum]&192) walloverpicnum += animateoffs(walloverpicnum,wallnum+16384); if (walloverpicnum>=0 && picanm[walloverpicnum]&192) walloverpicnum += animateoffs(walloverpicnum,wallnum+16384);
if (nwallnum >= 0 && nwallnum < numwalls) if (nwallnum >= 0 && nwallnum < numwalls)
{ {
nwallpicnum = wall[nwallnum].picnum; nwallpicnum = wall[nwallnum].picnum;