[KMTESTS:RTL]
authorThomas Faber <thomas.faber@reactos.org>
Tue, 12 Aug 2014 07:47:08 +0000 (07:47 +0000)
committerThomas Faber <thomas.faber@reactos.org>
Tue, 12 Aug 2014 07:47:08 +0000 (07:47 +0000)
- Fix a stack buffer overflow in the RtlMemory test

svn path=/trunk/; revision=63870

rostests/kmtests/rtl/RtlMemory.c

index 154ce8e..1f5bfa1 100644 (file)
@@ -316,7 +316,7 @@ START_TEST(RtlMemory)
     KeRaiseIrql(HIGH_LEVEL, &Irql);
 
     /* RtlCompareMemoryUlong */
-    MakeBuffer(Buffer, 8, 0x55, Size - 4, 0, 0);
+    MakeBuffer(Buffer, 8, 0x55, Size - 8, 0, 0);
     RetSize = RtlCompareMemoryUlong(Buffer, sizeof(ULONG), 0x55555555LU);
     ok_eq_size(RetSize, 4);
     RetSize = RtlCompareMemoryUlong(Buffer + 1, sizeof(ULONG), 0x55555555LU);