Commit 2b7c5d82 authored by Richard Gobeille's avatar Richard Gobeille

Duke3d: fix potential OOB memory access through player .wackedbyactor member

parent 24e5d5fc
......@@ -4012,7 +4012,7 @@ void P_FragPlayer(int playerNum)
if (actor[pPlayer->i].picnum != APLAYERTOP)
if ((unsigned)pPlayer->wackedbyactor < MAXTILES && A_CheckEnemyTile(sprite[pPlayer->wackedbyactor].picnum))
if ((unsigned)pPlayer->wackedbyactor < MAXSPRITES && A_CheckEnemyTile(sprite[pPlayer->wackedbyactor].picnum))
Bsprintf(tempbuf, apStrings[OBITQUOTEINDEX + (krand() % g_numObituaries)], "A monster",
else if (actor[pPlayer->i].picnum == NUKEBUTTON)
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment