fixed crash with "autotest" due to clearing undefined bitmap rectangle
[rocksndiamonds.git] / src / libgame / system.c
index 196e15dc72d8777dacefdff7d390f4825a071687..c41fbef27494cd40806fbd4b8567f53d801da07b 100644 (file)
@@ -906,6 +906,9 @@ void FadeRectangle(int x, int y, int width, int height,
 void FillRectangle(Bitmap *bitmap, int x, int y, int width, int height,
                   Pixel color)
 {
+  if (program.headless)
+    return;
+
   if (DrawingDeactivated(x, y, width, height))
     return;