graphics: fix potential bad free of sprite->masks

This commit is contained in:
K. Lange 2018-11-19 21:03:54 +09:00
parent d96bc4f2cb
commit f8791b157e

View File

@ -403,6 +403,7 @@ void load_sprite(sprite_t * sprite, char * filename) {
sprite->width = width;
sprite->height = height;
sprite->bitmap = malloc(sizeof(uint32_t) * width * height);
sprite->masks = NULL;
for (y = 0; y < height; ++y) {
for (x = 0; x < width; ++x) {