]> git.unchartedbackwaters.co.uk Git - francis/winuae.git/commitdiff
Fix console DMA debugger output
authorToni Wilen <twilen@winuae.net>
Sun, 7 Aug 2022 17:42:16 +0000 (20:42 +0300)
committerToni Wilen <twilen@winuae.net>
Sun, 7 Aug 2022 17:42:16 +0000 (20:42 +0300)
debug.cpp

index 91e2ec21faa5cc413c64891f02d5ba3d5bfcd854..6747423f6961fc9df6495335127243f9609c9b6e 100644 (file)
--- 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);