Fix some warnings; set gfx_white_texture to 0 in deinit function at the

end
This commit is contained in:
twinaphex 2021-09-13 20:52:57 +02:00
parent 90775e7306
commit 868a4bf3fc
2 changed files with 3 additions and 2 deletions

View File

@ -1307,6 +1307,7 @@ void gfx_display_deinit_white_texture(void)
{
if (gfx_white_texture)
video_driver_texture_unload(&gfx_white_texture);
gfx_white_texture = 0;
}
void gfx_display_init_white_texture(void)

View File

@ -266,9 +266,9 @@ static uint8_t *rtga_tga_load(rtga_context *s,
int RLE_repeating = 0;
int RLE_count = 0;
int read_next_pixel = 1;
/* Needs to be at least 18 bytes to silence a GCC warning,
/* Needs to be at least 24 bytes to silence a GCC warning,
* only 4 are actually used */
unsigned char raw_data[18] = {0};
unsigned char raw_data[24] = {0};
unsigned char *tga_palette = NULL;
/* Do I need to load a palette? */