Author: pschweitzer
Date: Sun Nov 23 19:53:16 2014
New Revision: 65468
URL:
http://svn.reactos.org/svn/reactos?rev=65468&view=rev
Log:
[NTFS]
- Implement NtfsGetPositionInformation(), NtfsGetBasicInformation()
- Add a fixme in NtfsGetStandardInformation() regarding the number of links
Modified:
trunk/reactos/drivers/filesystems/ntfs/finfo.c
Modified: trunk/reactos/drivers/filesystems/ntfs/finfo.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/ntfs/f…
==============================================================================
--- trunk/reactos/drivers/filesystems/ntfs/finfo.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/filesystems/ntfs/finfo.c [iso-8859-1] Sun Nov 23 19:53:16 2014
@@ -59,7 +59,7 @@
StandardInfo->AllocationSize = Fcb->RFCB.AllocationSize;
StandardInfo->EndOfFile = Fcb->RFCB.FileSize;
- StandardInfo->NumberOfLinks = 0;
+ StandardInfo->NumberOfLinks = 0; /* FIXME */
StandardInfo->DeletePending = FALSE;
StandardInfo->Directory = NtfsFCBIsDirectory(Fcb);
@@ -75,15 +75,12 @@
PFILE_POSITION_INFORMATION PositionInfo,
PULONG BufferLength)
{
- UNREFERENCED_PARAMETER(FileObject);
-
DPRINT("NtfsGetPositionInformation() called\n");
if (*BufferLength < sizeof(FILE_POSITION_INFORMATION))
return STATUS_BUFFER_OVERFLOW;
- PositionInfo->CurrentByteOffset.QuadPart = 0;
-// FileObject->CurrentByteOffset.QuadPart;
+ PositionInfo->CurrentByteOffset.QuadPart =
FileObject->CurrentByteOffset.QuadPart;
DPRINT("Getting position %I64x\n",
PositionInfo->CurrentByteOffset.QuadPart);
@@ -102,29 +99,19 @@
PFILE_BASIC_INFORMATION BasicInfo,
PULONG BufferLength)
{
+ PFILENAME_ATTRIBUTE FileName = &Fcb->Entry;
+
DPRINT("NtfsGetBasicInformation() called\n");
if (*BufferLength < sizeof(FILE_BASIC_INFORMATION))
return STATUS_BUFFER_OVERFLOW;
-#if 0
- CdfsDateTimeToFileTime(Fcb,
- &BasicInfo->CreationTime);
- CdfsDateTimeToFileTime(Fcb,
- &BasicInfo->LastAccessTime);
- CdfsDateTimeToFileTime(Fcb,
- &BasicInfo->LastWriteTime);
- CdfsDateTimeToFileTime(Fcb,
- &BasicInfo->ChangeTime);
-
- CdfsFileFlagsToAttributes(Fcb,
- &BasicInfo->FileAttributes);
-#else
- UNREFERENCED_PARAMETER(FileObject);
- UNREFERENCED_PARAMETER(Fcb);
- UNREFERENCED_PARAMETER(DeviceObject);
- UNREFERENCED_PARAMETER(BasicInfo);
-#endif
+ BasicInfo->CreationTime.QuadPart = FileName->CreationTime;
+ BasicInfo->LastAccessTime.QuadPart = FileName->LastAccessTime;
+ BasicInfo->LastWriteTime.QuadPart = FileName->LastWriteTime;
+ BasicInfo->ChangeTime.QuadPart = FileName->ChangeTime;
+
+ NtfsFileFlagsToAttributes(FileName->FileAttributes,
&BasicInfo->FileAttributes);
*BufferLength -= sizeof(FILE_BASIC_INFORMATION);