diff --git a/src/core/gpu_commands.cpp b/src/core/gpu_commands.cpp index 4c5716fa4..4db537e43 100644 --- a/src/core/gpu_commands.cpp +++ b/src/core/gpu_commands.cpp @@ -459,7 +459,9 @@ bool GPU::HandleFillRectangleCommand() Log_DebugPrintf("Fill VRAM rectangle offset=(%u,%u), size=(%u,%u)", dst_x, dst_y, width, height); - FillVRAM(dst_x, dst_y, width, height, color); + if (width > 0 && height > 0) + FillVRAM(dst_x, dst_y, width, height, color); + m_stats.num_vram_fills++; AddCommandTicks(46 + ((width / 8) + 9) * height); EndCommand();