Commit caa7a4f3 authored by Evan Ramos's avatar Evan Ramos
Browse files

Fix OOB in polymost_spriteIsModelOrVoxel

From-SVN: r8740
parent 5568bb40
......@@ -2777,7 +2777,7 @@ int32_t polymost_spriteHasTranslucency(tspritetype const * const tspr)
int32_t polymost_spriteIsModelOrVoxel(tspritetype const * const tspr)
{
if (spriteext[tspr->owner].flags&SPREXT_NOTMD)
if ((unsigned)tspr->owner < MAXSPRITES && spriteext[tspr->owner].flags&SPREXT_NOTMD)
return false;
if (usemodels && tile2model[Ptile2tile(tspr->picnum, tspr->pal)].modelid >= 0 &&
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment