Windows: Use the allocation size from the service
authorpete scott <pscott@kerneldrivers.com>
Wed, 24 Sep 2014 17:49:38 +0000 (11:49 -0600)
committerJeffrey Altman <jaltman@your-file-system.com>
Thu, 25 Sep 2014 12:31:09 +0000 (08:31 -0400)
The prior patchset modified the service AllocationSize return value
to count the number of 1KB units.  Use the value from the service
without modification.  This corrects an inconsistency in the
FileStandardInformation response.

Change-Id: I9a5f0a4f43aa12de903875b6ed4c5493e37b0163
Reviewed-on: http://gerrit.openafs.org/11491
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>

src/WINNT/afsrdr/kernel/lib/AFSFileInfo.cpp

index 48fb3fd..020a8c6 100644 (file)
@@ -957,7 +957,7 @@ AFSQueryStandardInfo( IN PIRP Irp,
         Buffer->NumberOfLinks = 1;
         Buffer->DeletePending = BooleanFlagOn( pCcb->DirectoryCB->Flags, AFS_DIR_ENTRY_PENDING_DELETE);
 
-        Buffer->AllocationSize.QuadPart = (ULONGLONG)((DirectoryCB->ObjectInformation->AllocationSize.QuadPart/PAGE_SIZE) + 1) * PAGE_SIZE;
+       Buffer->AllocationSize.QuadPart = DirectoryCB->ObjectInformation->AllocationSize.QuadPart;
 
         Buffer->EndOfFile = DirectoryCB->ObjectInformation->EndOfFile;