From: Toni Wilen Date: Wed, 11 Feb 2026 19:43:11 +0000 (+0200) Subject: Fix max screen width check X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=29ee2e79cff100aeb6535678616e07b1211e3ed3;p=francis%2Fwinuae.git Fix max screen width check --- diff --git a/drawing.cpp b/drawing.cpp index f79f0134..a314596f 100644 --- a/drawing.cpp +++ b/drawing.cpp @@ -5674,9 +5674,11 @@ static void get_line(int monid, int gfx_ypos, enum nln_how how, int lol_shift_pr } } - if ((denise_pixtotal_max << (1 + hresolution)) > vb->inwidth) { - denise_pixtotal_max = vb->inwidth >> (1 + hresolution); + int maxw = (uae_u32*)xlinebuffer_end - buf1; + if ((denise_pixtotal_max << (1 + hresolution)) > maxw) { + denise_pixtotal_max = maxw >> (1 + hresolution); } + if (xshift > 0) { denise_pixtotal_max -= xshift; }