@samitouri / QOSamiQemu / commits / efa7244b2a

ui/vnc: remove redundant rows computation

"rows" was already computed in an earlier commit 3543c2b855 ("ui/vnc: fix OOB write in vnc_refresh_lossy_rect"). Fixes: e650e4fe0f ("ui/vnc: fix out-of-bounds write in lossy refresh dirty marking") Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>

Marc-André Lureau committed Jul 21, 2026 at 19:26 UTC efa7244b2a0bd5e40ec334dbec4a09af0134d91f
1 file changed -1
ui/vnc.c
-1
@@ -3016,7 +3016,6 @@ static int vnc_refresh_lossy_rect(VncDisplay *vd, int x, int y,
3016
3017 y = QEMU_ALIGN_DOWN(y, VNC_STAT_RECT);
3018 x = QEMU_ALIGN_DOWN(x, VNC_STAT_RECT);
3019 - rows = MIN(VNC_STAT_RECT, height - y);
3019
3020 rows = MIN(VNC_STAT_RECT, height - y);
3021 if (rows <= 0) {