mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Merge branch 'fix-give-command-bounds' into 'master'
Fix potential out-of-bounds exploit with give command Closes #698 See merge request KartKrew/Kart!1874
This commit is contained in:
commit
22e2b97171
1 changed files with 2 additions and 0 deletions
|
|
@ -6069,6 +6069,8 @@ static void Got_Cheat(UINT8 **cp, INT32 playernum)
|
|||
UINT8 powerup = READUINT8(*cp);
|
||||
UINT16 time = READUINT16(*cp);
|
||||
|
||||
powerup = min(powerup, LASTPOWERUP);
|
||||
|
||||
// FIXME: we should have actual KITEM_ name array
|
||||
const char *powerupname = cv_kartdebugitem.PossibleValue[
|
||||
1 + NUMKARTITEMS + (powerup - FIRSTPOWERUP)].strvalue;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue