Skip to content

Commit e2305c3

Browse files
committed
Remove unnecessary subtraction
1 parent 5177b22 commit e2305c3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src_c/surface.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1567,9 +1567,9 @@ surf_convert(pgSurfaceObject *self, PyObject *args)
15671567
* palette.
15681568
*/
15691569
SDL_Palette *palette =
1570-
SDL_AllocPalette(default_palette_size - 1);
1570+
SDL_AllocPalette(default_palette_size);
15711571
SDL_SetPaletteColors(palette, default_palette_colors, 0,
1572-
default_palette_size - 1);
1572+
default_palette_size);
15731573
format.palette = palette;
15741574
}
15751575
}

0 commit comments

Comments
 (0)