diff --git a/src/graphics.c b/src/graphics.c index 4d53ec2de..00616a539 100644 --- a/src/graphics.c +++ b/src/graphics.c @@ -3790,6 +3790,7 @@ void draw_rgba_image(pixel *vid, unsigned char *data, int x, int y, float alpha) unsigned char w, h; int i, j; unsigned char r, g, b, a; + if (!data) return; w = *(data++)&0xFF; h = *(data++)&0xFF; for (j=0; j