v_video: fix cv_palettenum bounds check
mhhm yeah
This commit is contained in:
1 parent
f2b46fd148
commit
07fc0eb03a
1 file changed
+1
-1
+1
-1
@@ -555,7 +555,7 @@ void V_SetPalette(INT32 palettenum)
|
||||
{
|
||||
palettenum = cv_palettenum.value;
|
||||
|
||||
if (palettenum * 256U > currentPaletteSize - 256)
|
||||
if (palettenum * 256U > (currentPaletteSize - 256) / 3)
|
||||
{
|
||||
CONS_Alert(CONS_WARNING, "cv_palettenum %d out of range\n", palettenum);
|
||||
palettenum = 0;
|
||||
|
||||
Reference in new issue
Block a user