From: Holger Schemel Date: Fri, 23 Feb 2024 00:01:39 +0000 (+0100) Subject: fixed crash bug with masked blitting in headless mode X-Git-Tag: 4.4.0.0-test-1~313 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=a863de3d5f7a903a1ec68d245861ce0fdf577323;p=rocksndiamonds.git fixed crash bug with masked blitting in headless mode --- diff --git a/src/libgame/system.c b/src/libgame/system.c index f824ac51..e83df10b 100644 --- a/src/libgame/system.c +++ b/src/libgame/system.c @@ -938,6 +938,12 @@ void BlitBitmapMasked(Bitmap *src_bitmap, Bitmap *dst_bitmap, int src_x, int src_y, int width, int height, int dst_x, int dst_y) { + if (program.headless) + return; + + if (src_bitmap == NULL || dst_bitmap == NULL) + return; + if (DrawingDeactivated(dst_x, dst_y)) return;