From d0936f618b04fa5814eff235121f743f343bd6f7 Mon Sep 17 00:00:00 2001 From: Volker Ruppert Date: Tue, 26 Jun 2018 17:58:11 +0000 Subject: [PATCH] Attempt to fix crash that happens in some cases (suggested by Luigi B.). --- bochs/iodev/display/banshee.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bochs/iodev/display/banshee.cc b/bochs/iodev/display/banshee.cc index 4b1e4a168..4829e75d3 100644 --- a/bochs/iodev/display/banshee.cc +++ b/bochs/iodev/display/banshee.cc @@ -823,6 +823,8 @@ void bx_banshee_c::mem_read(bx_phy_address addr, unsigned len, void *data) x = (offset << 0) & ((1 << v->fbi.lfb_stride) - 1); y = (offset >> v->fbi.lfb_stride) & 0x7ff; offset = (v->fbi.lfb_base + y * pitch + x) & v->fbi.mask; + } else { + offset &= v->fbi.mask; } value = 0; for (i = 0; i < len; i++) {