[KMTESTS:MM]
authorPierre Schweitzer <pierre@reactos.org>
Fri, 11 Nov 2016 10:44:51 +0000 (10:44 +0000)
committerPierre Schweitzer <pierre@reactos.org>
Fri, 11 Nov 2016 10:44:51 +0000 (10:44 +0000)
Bugfix for IRP_MJ_SET_INFORMATION/FileEndOfFileInformation: really set the information. The test still works fine in Windows and still fails hard in ReactOS.

svn path=/trunk/; revision=73200

rostests/kmtests/ntos_mm/NtCreateSection_drv.c

index 61ec9e2..8869308 100644 (file)
@@ -477,6 +477,7 @@ TestIrpHandler(
                 ok_bool_false(IoStack->Parameters.SetFile.AdvanceOnly, "AdvanceOnly set!\n");
                 ok(EOFInfo->EndOfFile.QuadPart > Fcb->Header.AllocationSize.QuadPart, "New size smaller\n");
 
                 ok_bool_false(IoStack->Parameters.SetFile.AdvanceOnly, "AdvanceOnly set!\n");
                 ok(EOFInfo->EndOfFile.QuadPart > Fcb->Header.AllocationSize.QuadPart, "New size smaller\n");
 
+                Fcb->Header.AllocationSize.QuadPart = EOFInfo->EndOfFile.QuadPart;
                 if (CcIsFileCached(IoStack->FileObject))
                 {
                     CcSetFileSizes(IoStack->FileObject, (PCC_FILE_SIZES)(&(Fcb->Header.AllocationSize)));
                 if (CcIsFileCached(IoStack->FileObject))
                 {
                     CcSetFileSizes(IoStack->FileObject, (PCC_FILE_SIZES)(&(Fcb->Header.AllocationSize)));