Author: hbelusca
Date: Sat Apr 18 15:38:51 2015
New Revision: 67261
URL:
http://svn.reactos.org/svn/reactos?rev=67261&view=rev
Log:
[NTVDM]: Fix the fix of r67238 (inversion min/max).
Modified:
trunk/reactos/subsystems/mvdm/ntvdm/hardware/video/vga.c
Modified: trunk/reactos/subsystems/mvdm/ntvdm/hardware/video/vga.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/mvdm/ntvdm/hard…
==============================================================================
--- trunk/reactos/subsystems/mvdm/ntvdm/hardware/video/vga.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/mvdm/ntvdm/hardware/video/vga.c [iso-8859-1] Sat Apr 18
15:38:51 2015
@@ -1910,7 +1910,7 @@
PUCHAR BufPtr = (PUCHAR)Buffer;
DPRINT("VgaReadMemory: Address 0x%08X, Size %lu\n", Address, Size);
- Address = min(max(Address, VgaGetVideoLimitAddress() - 1),
VgaGetVideoBaseAddress());
+ Address = min(max(Address, VgaGetVideoBaseAddress()), VgaGetVideoLimitAddress());
Size = min(Size, VgaGetVideoLimitAddress() - Address + 1);
/* Ignore if video RAM access is disabled */
@@ -1939,7 +1939,7 @@
PUCHAR BufPtr = (PUCHAR)Buffer;
DPRINT("VgaWriteMemory: Address 0x%08X, Size %lu\n", Address, Size);
- Address = min(max(Address, VgaGetVideoLimitAddress() - 1),
VgaGetVideoBaseAddress());
+ Address = min(max(Address, VgaGetVideoBaseAddress()), VgaGetVideoLimitAddress());
Size = min(Size, VgaGetVideoLimitAddress() - Address + 1);
/* Ignore if video RAM access is disabled */