Author: pschweitzer
Date: Sat Jun 28 13:39:19 2008
New Revision: 34166
URL:
http://svn.reactos.org/svn/reactos?rev=34166&view=rev
Log:
- No need to define a second name to driver.
- Fixed a FIXME: Guard Cache Initialization with SEH
- Fixed build.......
- Updated some headers
Modified:
branches/pierre-fsd/drivers/filesystems/fastfat/dir.c
branches/pierre-fsd/drivers/filesystems/fastfat/fsctl.c
branches/pierre-fsd/drivers/filesystems/fastfat/iface.c
Modified: branches/pierre-fsd/drivers/filesystems/fastfat/dir.c
URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
==============================================================================
--- branches/pierre-fsd/drivers/filesystems/fastfat/dir.c [iso-8859-1] (original)
+++ branches/pierre-fsd/drivers/filesystems/fastfat/dir.c [iso-8859-1] Sat Jun 28 13:39:19
2008
@@ -1,7 +1,7 @@
/*
* COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS kernel
- * FILE: drivers/fs/vfat/dir.c
+ * FILE: drivers/filesystems/fastfat/dir.c
* PURPOSE: VFAT Filesystem : directory control
* UPDATE HISTORY:
19-12-1998 : created
@@ -471,6 +471,7 @@
return RC;
}
+#if 0
static NTSTATUS NotifyChange (PVFAT_IRP_CONTEXT IrpContext) //bug 2821
{
PIRP pIrp;
@@ -517,6 +518,7 @@
return RC;
}
+#endif
NTSTATUS VfatDirectoryControl (PVFAT_IRP_CONTEXT IrpContext)
Modified: branches/pierre-fsd/drivers/filesystems/fastfat/fsctl.c
URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
==============================================================================
--- branches/pierre-fsd/drivers/filesystems/fastfat/fsctl.c [iso-8859-1] (original)
+++ branches/pierre-fsd/drivers/filesystems/fastfat/fsctl.c [iso-8859-1] Sat Jun 28
13:39:19 2008
@@ -19,7 +19,7 @@
/*
* COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS kernel
- * FILE: drivers/fs/vfat/fsctl.c
+ * FILE: drivers/filesystems/fastfat/fsctl.c
* PURPOSE: VFAT Filesystem
*/
@@ -537,12 +537,21 @@
Fcb->RFCB.ValidDataLength = Fcb->RFCB.FileSize;
Fcb->RFCB.AllocationSize = Fcb->RFCB.FileSize;
- /* FIXME: Guard by SEH. */
- CcInitializeCacheMap(DeviceExt->FATFileObject,
- (PCC_FILE_SIZES)(&Fcb->RFCB.AllocationSize),
- FALSE,
- &VfatGlobalData->CacheMgrCallbacks,
- Fcb);
+ _SEH_TRY
+ {
+ CcInitializeCacheMap(DeviceExt->FATFileObject,
+ (PCC_FILE_SIZES)(&Fcb->RFCB.AllocationSize),
+ FALSE,
+ &VfatGlobalData->CacheMgrCallbacks,
+ Fcb);
+ }
+ _SEH_HANDLE
+ {
+ Status = _SEH_GetExceptionCode();
+ }
+ _SEH_END;
+ if (!NT_SUCCESS(Status))
+ goto ByeBye;
DeviceExt->LastAvailableCluster = 2;
ExInitializeResourceLite(&DeviceExt->FatResource);
@@ -592,7 +601,7 @@
{
// cleanup
if (DeviceExt && DeviceExt->FATFileObject)
- ObDereferenceObject (DeviceExt->FATFileObject);
+ ObDereferenceObject(DeviceExt->FATFileObject);
if (Fcb)
vfatDestroyFCB(Fcb);
if (Ccb)
Modified: branches/pierre-fsd/drivers/filesystems/fastfat/iface.c
URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
==============================================================================
--- branches/pierre-fsd/drivers/filesystems/fastfat/iface.c [iso-8859-1] (original)
+++ branches/pierre-fsd/drivers/filesystems/fastfat/iface.c [iso-8859-1] Sat Jun 28
13:39:19 2008
@@ -18,7 +18,7 @@
*/
/*
* PROJECT: ReactOS kernel
- * FILE: drivers/fs/vfat/iface.c
+ * FILE: drivers/filesystems/fastfat/iface.c
* PURPOSE: VFAT Filesystem
* PROGRAMMER: Jason Filby (jasonfilby(a)yahoo.com)
*/
@@ -50,28 +50,12 @@
NTSTATUS Status;
Status = IoCreateDevice(DriverObject,
- sizeof(VFAT_GLOBAL_DATA),
- &DeviceName,
- FILE_DEVICE_DISK_FILE_SYSTEM,
- 0,
- FALSE,
- &DeviceObject);
-
- if (Status == STATUS_OBJECT_NAME_EXISTS ||
- Status == STATUS_OBJECT_NAME_COLLISION)
- {
- /* Try an other name, if 'Fat' is already in use. 'Fat' is also
used by fastfat.sys on W2K */
- RtlInitUnicodeString(&DeviceName, L"\\RosFat");
- Status = IoCreateDevice(DriverObject,
- sizeof(VFAT_GLOBAL_DATA),
- &DeviceName,
- FILE_DEVICE_DISK_FILE_SYSTEM,
- 0,
- FALSE,
- &DeviceObject);
- }
-
-
+ sizeof(VFAT_GLOBAL_DATA),
+ &DeviceName,
+ FILE_DEVICE_DISK_FILE_SYSTEM,
+ 0,
+ FALSE,
+ &DeviceObject);
if (!NT_SUCCESS(Status))
{