Author: fireball
Date: Thu Mar 6 10:39:36 2008
New Revision: 32579
URL:
http://svn.reactos.org/svn/reactos?rev=3D32579&view=3Drev
Log:
- Our precious kernel should be handled with love and care, with thorough c=
heck of every change going in! Not with "commit-and-forget" fashion.
- MmSecureVirtualMemory fails in case of Length =3D 0 too.
Modified:
trunk/reactos/ntoskrnl/mm/virtual.c
Modified: trunk/reactos/ntoskrnl/mm/virtual.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/mm/virtual.c=
?rev=3D32579&r1=3D32578&r2=3D32579&view=3Ddiff
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
--- trunk/reactos/ntoskrnl/mm/virtual.c (original)
+++ trunk/reactos/ntoskrnl/mm/virtual.c Thu Mar 6 10:39:36 2008
@@ -963,7 +963,7 @@
ULONG Mode)
{
/* Only works for user space */
- if (((ULONG_PTR)Address > (ULONG_PTR)Address + Length) ||
+ if (((ULONG_PTR)Address >=3D (ULONG_PTR)Address + Length) ||
((ULONG_PTR)MmHighestUserAddress < (ULONG_PTR)Address + Length))
{
return NULL;