]> git.unchartedbackwaters.co.uk Git - francis/winuae.git/commitdiff
Allow VPOSW vpos backwards move if previous vpos is out of range, in same field.
authorToni Wilen <twilen@winuae.net>
Sat, 29 Apr 2023 12:27:27 +0000 (15:27 +0300)
committerToni Wilen <twilen@winuae.net>
Sat, 29 Apr 2023 12:27:27 +0000 (15:27 +0300)
custom.cpp

index b71f833b5fe7a9e1263273519a4908e850ff92d6..daecaa9a3094d99dc97980ff6dac59505db4abae 100644 (file)
@@ -7899,7 +7899,8 @@ static void VHPOSW_delayed(uae_u32 v)
 #endif
        }
        // don't allow backwards vpos (at least for now)
-       if (newvpos < oldvpos) {
+       // allow backwards if old vpos was out of range
+       if (newvpos < oldvpos && oldvpos <= maxvpos) {
                newvpos = oldvpos;
        } else if (newvpos < minfirstline && oldvpos < minfirstline) {
                newvpos = oldvpos;