From 6a1cfd30b1a6859e0a0c2ebffe4546e5ad4fad6b Mon Sep 17 00:00:00 2001 From: Toni Wilen Date: Sun, 7 Aug 2022 20:42:16 +0300 Subject: [PATCH] Fix console DMA debugger output --- debug.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/debug.cpp b/debug.cpp index 91e2ec21..6747423f 100644 --- a/debug.cpp +++ b/debug.cpp @@ -2392,9 +2392,13 @@ static void decode_dma_record (int hpos, int vpos, int toggle, bool logfile) maxh++; dr++; } - dr = dr_start; + dr = dr_start + hpos; if (!logfile && maxh - h > 80) { + int maxh2 = maxh; maxh = h + 80; + if (maxh > maxh2) { + maxh = maxh2; + } } while (h < maxh) { int cols = (logfile ? 16 : 8); -- 2.47.3