2003-03-16 Casper S. Hornstrup <chorns@users.sourceforge.net>
authorCasper Hornstrup <chorns@users.sourceforge.net>
Sun, 16 Mar 2003 13:18:49 +0000 (13:18 +0000)
committerCasper Hornstrup <chorns@users.sourceforge.net>
Sun, 16 Mar 2003 13:18:49 +0000 (13:18 +0000)
* ntoskrnl/fs/util.c (FsRtlGetFileSize): Implement.

svn path=/trunk/; revision=4314

reactos/ChangeLog
reactos/ntoskrnl/fs/util.c

index b33f581..71194a0 100644 (file)
@@ -1,3 +1,7 @@
+2003-03-16  Casper S. Hornstrup  <chorns@users.sourceforge.net>
+
+       * ntoskrnl/fs/util.c (FsRtlGetFileSize): Implement.
+
 2003-03-16  Casper S. Hornstrup  <chorns@users.sourceforge.net>
 
        * lib/ntdll/rtl/nls.c (RtlCustomCPToUnicodeN, RtlMultiByteToUnicodeN,
 2003-03-16  Casper S. Hornstrup  <chorns@users.sourceforge.net>
 
        * lib/ntdll/rtl/nls.c (RtlCustomCPToUnicodeN, RtlMultiByteToUnicodeN,
index b489816..0fe5406 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: util.c,v 1.12 2002/09/08 10:23:20 chorns Exp $
+/* $Id: util.c,v 1.13 2003/03/16 13:18:49 chorns Exp $
  *
  * reactos/ntoskrnl/fs/util.c
  *
  *
  * reactos/ntoskrnl/fs/util.c
  *
@@ -241,7 +241,21 @@ FsRtlGetFileSize (
     IN OUT PLARGE_INTEGER   FileSize
     )
 {
     IN OUT PLARGE_INTEGER   FileSize
     )
 {
-       return STATUS_NOT_IMPLEMENTED;
+       FILE_STANDARD_INFORMATION Info;
+       NTSTATUS Status;
+       ULONG Length;
+
+       Status = IoQueryFileInformation(FileObject,
+               FileStandardInformation,
+               sizeof(Info),
+               &Info,
+               &Length);
+       if (NT_SUCCESS(Status))
+               {
+                       FileSize->QuadPart = Info.EndOfFile.QuadPart;
+               }
+
+       return Status;
 }
 
 
 }