Author: pschweitzer Date: Sun Nov 27 10:49:33 2016 New Revision: 73392
URL: http://svn.reactos.org/svn/reactos?rev=73392&view=rev Log: [KMTESTS:MM] Check the first byte is really null, in spite of the hack writing.
CORE-11819 CORE-12475
Modified: trunk/rostests/kmtests/ntos_mm/NtCreateSection_drv.c trunk/rostests/kmtests/ntos_mm/NtCreateSection_user.c
Modified: trunk/rostests/kmtests/ntos_mm/NtCreateSection_drv.c URL: http://svn.reactos.org/svn/reactos/trunk/rostests/kmtests/ntos_mm/NtCreateSe... ============================================================================== --- trunk/rostests/kmtests/ntos_mm/NtCreateSection_drv.c [iso-8859-1] (original) +++ trunk/rostests/kmtests/ntos_mm/NtCreateSection_drv.c [iso-8859-1] Sun Nov 27 10:49:33 2016 @@ -404,7 +404,8 @@ { Fcb = IoStack->FileObject->FsContext; ok(Fcb != NULL, "Null pointer!\n"); - if (IoStack->FileObject->PrivateCacheMap != NULL) + if (IoStack->FileObject->SectionObjectPointer != NULL && + IoStack->FileObject->SectionObjectPointer->SharedCacheMap != NULL) { CcFlushCache(&Fcb->SectionObjectPointers, NULL, 0, NULL); CcPurgeCacheSection(&Fcb->SectionObjectPointers, NULL, 0, FALSE);
Modified: trunk/rostests/kmtests/ntos_mm/NtCreateSection_user.c URL: http://svn.reactos.org/svn/reactos/trunk/rostests/kmtests/ntos_mm/NtCreateSe... ============================================================================== --- trunk/rostests/kmtests/ntos_mm/NtCreateSection_user.c [iso-8859-1] (original) +++ trunk/rostests/kmtests/ntos_mm/NtCreateSection_user.c [iso-8859-1] Sun Nov 27 10:49:33 2016 @@ -53,6 +53,7 @@ ok_eq_hex(Status, STATUS_SUCCESS);
KmtStartSeh(); + ok(((PCHAR)Buffer)[0] == 0, "First byte is not null! %x", ((PCHAR)Buffer)[0]); memset(Buffer, 0xBA, 512); KmtEndSeh(STATUS_SUCCESS);
@@ -78,6 +79,7 @@ ok_eq_hex(Status, STATUS_SUCCESS);
KmtStartSeh(); + ok(((PCHAR)Buffer)[0] == 0, "First byte is not null! %x", ((PCHAR)Buffer)[0]); memset(Buffer, 0xBA, 4096); KmtEndSeh(STATUS_SUCCESS);
@@ -103,6 +105,7 @@ ok_eq_hex(Status, STATUS_SUCCESS);
KmtStartSeh(); + ok(((PCHAR)Buffer)[0] == 0, "First byte is not null! %x", ((PCHAR)Buffer)[0]); memset(Buffer, 0xBA, 512); KmtEndSeh(STATUS_SUCCESS);
@@ -128,6 +131,7 @@ ok_eq_hex(Status, STATUS_SUCCESS);
KmtStartSeh(); + ok(((PCHAR)Buffer)[0] == 0, "First byte is not null! %x", ((PCHAR)Buffer)[0]); memset(Buffer, 0xBA, 4096); KmtEndSeh(STATUS_SUCCESS);
@@ -165,6 +169,7 @@ ok_eq_hex(Status, STATUS_SUCCESS);
KmtStartSeh(); + ok(((PCHAR)Buffer)[0] == 0, "First byte is not null! %x", ((PCHAR)Buffer)[0]); memset(Buffer, 0xBA, 512); KmtEndSeh(STATUS_SUCCESS);
@@ -190,6 +195,7 @@ ok_eq_hex(Status, STATUS_SUCCESS);
KmtStartSeh(); + ok(((PCHAR)Buffer)[0] == 0, "First byte is not null! %x", ((PCHAR)Buffer)[0]); memset(Buffer, 0xBA, 4096); KmtEndSeh(STATUS_SUCCESS);
@@ -215,6 +221,7 @@ ok_eq_hex(Status, STATUS_SUCCESS);
KmtStartSeh(); + ok(((PCHAR)Buffer)[0] == 0, "First byte is not null! %x", ((PCHAR)Buffer)[0]); memset(Buffer, 0xBA, 512); KmtEndSeh(STATUS_SUCCESS);
@@ -240,6 +247,7 @@ ok_eq_hex(Status, STATUS_SUCCESS);
KmtStartSeh(); + ok(((PCHAR)Buffer)[0] == 0, "First byte is not null! %x", ((PCHAR)Buffer)[0]); memset(Buffer, 0xBA, 4096); KmtEndSeh(STATUS_SUCCESS);