Fix another out-of-bounds array access
This one involves the Spur.
This commit is contained in:
parent
f7a8a260a4
commit
6fd6a416cd
1 changed files with 5 additions and 0 deletions
|
@ -2179,7 +2179,12 @@ void ActBullet_SpurTail(BULLET *bul, int level)
|
||||||
bul->ani_no = bul->count1 - 20;
|
bul->ani_no = bul->count1 - 20;
|
||||||
|
|
||||||
if (bul->ani_no > 2)
|
if (bul->ani_no > 2)
|
||||||
|
{
|
||||||
bul->cond = 0;
|
bul->cond = 0;
|
||||||
|
#ifdef FIX_BUGS
|
||||||
|
return; // Avoid accessing the RECT arrays with an out-of-bounds index
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
if (bul->damage && bul->life != 100)
|
if (bul->damage && bul->life != 100)
|
||||||
bul->damage = 0;
|
bul->damage = 0;
|
||||||
|
|
Loading…
Add table
Reference in a new issue