From 61fe294be51ed34229e303457d29de25390354dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Poussineau?= Date: Mon, 5 May 2008 14:50:43 +0000 Subject: [PATCH] Remove some warnings svn path=/trunk/; revision=33297 --- .../drivers/filesystems/ext2/inc/ext2fsd.h | 3 +- .../drivers/filesystems/ext2/src/cleanup.c | 2 - reactos/drivers/filesystems/ext2/src/close.c | 2 - reactos/drivers/filesystems/ext2/src/create.c | 13 +---- .../drivers/filesystems/ext2/src/devcntrl.c | 4 -- .../drivers/filesystems/ext2/src/dircntrl.c | 6 +-- .../drivers/filesystems/ext2/src/ext2init.c | 7 ++- reactos/drivers/filesystems/ext2/src/fastio.c | 54 ------------------- .../drivers/filesystems/ext2/src/fileinfo.c | 3 -- reactos/drivers/filesystems/ext2/src/flush.c | 4 -- reactos/drivers/filesystems/ext2/src/fsctrl.c | 2 - reactos/drivers/filesystems/ext2/src/io.c | 8 --- .../drivers/filesystems/ext2/src/metadata.c | 9 ---- reactos/drivers/filesystems/ext2/src/misc.c | 21 ++++---- reactos/drivers/filesystems/ext2/src/read.c | 10 +--- .../drivers/filesystems/ext2/src/shutdown.c | 3 -- .../drivers/filesystems/ext2/src/volinfo.c | 1 - reactos/drivers/filesystems/ext2/src/write.c | 2 - 18 files changed, 21 insertions(+), 133 deletions(-) diff --git a/reactos/drivers/filesystems/ext2/inc/ext2fsd.h b/reactos/drivers/filesystems/ext2/inc/ext2fsd.h index 9e8ef52224b..06fb44ba98b 100644 --- a/reactos/drivers/filesystems/ext2/inc/ext2fsd.h +++ b/reactos/drivers/filesystems/ext2/inc/ext2fsd.h @@ -130,8 +130,9 @@ extern Ext2Data Ext2GlobalData; } #ifdef EXT2_POOL_WITH_TAG + #define TAG(A, B, C, D) (ULONG)(((A)<<0) + ((B)<<8) + ((C)<<16) + ((D)<<24)) #define Ext2AllocatePool(PoolType,NumberOfBytes) \ - ExAllocatePoolWithTag( PoolType, NumberOfBytes, '2txE' ) + ExAllocatePoolWithTag( PoolType, NumberOfBytes, TAG ( 'E','x','t','2' ) ) #else #define Ext2AllocatePool(PoolType,NumberOfBytes) \ ExAllocatePool( PoolType, NumberOfBytes ) diff --git a/reactos/drivers/filesystems/ext2/src/cleanup.c b/reactos/drivers/filesystems/ext2/src/cleanup.c index 9f488c070e3..bacce9e46f9 100644 --- a/reactos/drivers/filesystems/ext2/src/cleanup.c +++ b/reactos/drivers/filesystems/ext2/src/cleanup.c @@ -113,12 +113,10 @@ BOOLEAN FirstAttempt ) PtrExt2VCB PtrVCB = NULL; PtrExt2NTRequiredFCB PtrReqdFCB = NULL; PERESOURCE PtrResourceAcquired = NULL; - IO_STATUS_BLOCK LocalIoStatus; BOOLEAN CompleteIrp = TRUE; BOOLEAN PostRequest = FALSE; BOOLEAN AcquiredVCB = FALSE; - BOOLEAN CanWait = FALSE; BOOLEAN BlockForResource; int i = 1; diff --git a/reactos/drivers/filesystems/ext2/src/close.c b/reactos/drivers/filesystems/ext2/src/close.c index f4d34ce6c00..32b9d009add 100644 --- a/reactos/drivers/filesystems/ext2/src/close.c +++ b/reactos/drivers/filesystems/ext2/src/close.c @@ -115,12 +115,10 @@ BOOLEAN FirstAttempt ) PtrExt2VCB PtrVCB = NULL; PtrExt2NTRequiredFCB PtrReqdFCB = NULL; PERESOURCE PtrResourceAcquired = NULL; - IO_STATUS_BLOCK LocalIoStatus; BOOLEAN CompleteIrp = TRUE; BOOLEAN PostRequest = FALSE; BOOLEAN AcquiredVCB = FALSE; - BOOLEAN CanWait = FALSE; BOOLEAN BlockForResource; int i = 1; diff --git a/reactos/drivers/filesystems/ext2/src/create.c b/reactos/drivers/filesystems/ext2/src/create.c index c22cf3934cb..c1de84ceb45 100644 --- a/reactos/drivers/filesystems/ext2/src/create.c +++ b/reactos/drivers/filesystems/ext2/src/create.c @@ -180,8 +180,6 @@ BOOLEAN FirstAttempt) UNICODE_STRING AbsolutePathName; UNICODE_STRING RenameLinkTargetFileName; - LARGE_INTEGER FileAllocationSize, FileEndOfFile; - ASSERT(PtrIrpContext); ASSERT(PtrIrp); @@ -472,12 +470,10 @@ BOOLEAN FirstAttempt) UNICODE_STRING RemainingName; UNICODE_STRING CurrentName; UNICODE_STRING NextRemainingName; - PEXT2_INODE PtrNextInode = NULL; ULONG CurrInodeNo = 0; PtrExt2FCB PtrCurrFCB = NULL; PtrExt2FCB PtrNextFCB = NULL; PFILE_OBJECT PtrCurrFileObject = NULL; - UINT NameBufferIndex; ULONG Type = 0; LARGE_INTEGER ZeroSize; BOOLEAN Found = FALSE; @@ -527,7 +523,6 @@ BOOLEAN FirstAttempt) if( OpenTargetDirectory ) { - int i; // // This is for a rename/move operation... // @@ -580,10 +575,10 @@ BOOLEAN FirstAttempt) // Quit searching... // - if( ( NextRemainingName.Length == 0 ) && + if( ( NextRemainingName.Length == 0 ) && ( ( RequestedDisposition == FILE_CREATE ) || ( RequestedDisposition == FILE_OPEN_IF) || - ( RequestedDisposition == FILE_OVERWRITE_IF) ) + ( RequestedDisposition == FILE_OVERWRITE_IF) ) ) { // @@ -618,7 +613,6 @@ BOOLEAN FirstAttempt) } else if( NextRemainingName.Length == 0 && OpenTargetDirectory ) { - int i; // // This is for a rename/move operation... // Just the last component was not found... @@ -1163,7 +1157,6 @@ PtrExt2FCB NTAPI Ext2LocateChildFCBInCore( { PtrExt2FCB PtrFCB = NULL; - ULONG InodeNo = 0; PLIST_ENTRY PtrEntry; if( IsListEmpty( &(PtrVCB->FCBListHead) ) ) @@ -1222,7 +1215,6 @@ ULONG NTAPI Ext2LocateFileInDisk ( ULONG *Type ) { - PtrExt2FCB PtrNewFCB = NULL; PFILE_OBJECT PtrFileObject = NULL; ULONG InodeNo = 0; @@ -1637,7 +1629,6 @@ BOOLEAN NTAPI Ext2SupersedeFile( { EXT2_INODE Inode; PtrExt2VCB PtrVCB = PtrFCB->PtrVCB; - ULONG i; Ext2InitializeFCBInodeInfo( PtrFCB ); diff --git a/reactos/drivers/filesystems/ext2/src/devcntrl.c b/reactos/drivers/filesystems/ext2/src/devcntrl.c index 37c96defb78..74942d66905 100644 --- a/reactos/drivers/filesystems/ext2/src/devcntrl.c +++ b/reactos/drivers/filesystems/ext2/src/devcntrl.c @@ -125,7 +125,6 @@ PIRP PtrIrp) PtrExt2CCB PtrCCB = NULL; PtrExt2VCB PtrVCB = NULL; ULONG IoControlCode = 0; - void *BufferPointer = NULL; try { @@ -165,9 +164,6 @@ PIRP PtrIrp) IoSetCompletionRoutine(PtrIrp, Ext2DevIoctlCompletion, NULL, TRUE, TRUE, TRUE); // Send the request. RC = IoCallDriver(PtrVCB->TargetDeviceObject, PtrIrp); - - try_exit: NOTHING; - } finally { diff --git a/reactos/drivers/filesystems/ext2/src/dircntrl.c b/reactos/drivers/filesystems/ext2/src/dircntrl.c index 72ec83dbbfe..9fd921326c3 100644 --- a/reactos/drivers/filesystems/ext2/src/dircntrl.c +++ b/reactos/drivers/filesystems/ext2/src/dircntrl.c @@ -109,7 +109,6 @@ PIRP PtrIrp) PFILE_OBJECT PtrFileObject = NULL; PtrExt2FCB PtrFCB = NULL; PtrExt2CCB PtrCCB = NULL; - PtrExt2VCB PtrVCB = NULL; // First, get a pointer to the current I/O stack location PtrIoStackLocation = IoGetCurrentIrpStackLocation(PtrIrp); @@ -189,7 +188,6 @@ PtrExt2FCB PtrFCB, PtrExt2CCB PtrCCB) { NTSTATUS RC = STATUS_SUCCESS; - BOOLEAN CompleteRequest = TRUE; BOOLEAN PostRequest = FALSE; PtrExt2NTRequiredFCB PtrReqdFCB = NULL; BOOLEAN CanWait = FALSE; @@ -212,9 +210,7 @@ PtrExt2CCB PtrCCB) BOOLEAN SearchWithWildCards = FALSE; PFILE_BOTH_DIR_INFORMATION BothDirInformation = NULL; - PFILE_FULL_DIR_INFORMATION FullDirInformation = NULL; PFILE_DIRECTORY_INFORMATION DirectoryInformation = NULL; - PFILE_NAMES_INFORMATION NamesInformation = NULL; PEXT2_DIR_ENTRY PtrDirEntry = NULL; @@ -233,7 +229,7 @@ PtrExt2CCB PtrCCB) PBCB PtrBCB = NULL; BYTE * PtrPinnedBlockBuffer = NULL; - unsigned int i,j; + unsigned int j; DebugTrace(DEBUG_TRACE_MISC, " === Querying Directory %S", PtrFCB->FCBName->ObjectName.Buffer ); diff --git a/reactos/drivers/filesystems/ext2/src/ext2init.c b/reactos/drivers/filesystems/ext2/src/ext2init.c index 96ff05d458a..01a82aa72ca 100644 --- a/reactos/drivers/filesystems/ext2/src/ext2init.c +++ b/reactos/drivers/filesystems/ext2/src/ext2init.c @@ -49,7 +49,6 @@ PUNICODE_STRING RegistryPath) // path to the registry key { NTSTATUS RC = STATUS_SUCCESS; UNICODE_STRING DriverDeviceName; - BOOLEAN RegisteredShutdown = FALSE; #if 0 Ext2BreakPoint(); @@ -128,7 +127,7 @@ PUNICODE_STRING RegistryPath) // path to the registry key // create a device object representing the driver itself // so that requests can be targeted to the driver ... // e.g. for a disk-based FSD, "mount" requests will be sent to - // this device object by the I/O Manager.\ + // this device object by the I/O Manager. // For a redirector/server, you may have applications // send "special" IOCTL's using this device object ... RtlInitUnicodeString(&DriverDeviceName, EXT2_FS_NAME); @@ -136,10 +135,10 @@ PUNICODE_STRING RegistryPath) // path to the registry key DriverObject, // our driver object 0, // don't need an extension for this object &DriverDeviceName,// name - can be used to "open" the driver - // see the book for alternate choices + // see the book for alternate choices FILE_DEVICE_DISK_FILE_SYSTEM, 0, // no special characteristics - // do not want this as an exclusive device, though you might + // do not want this as an exclusive device, though you might FALSE, &(Ext2GlobalData.Ext2DeviceObject)))) { diff --git a/reactos/drivers/filesystems/ext2/src/fastio.c b/reactos/drivers/filesystems/ext2/src/fastio.c index d0d96e9900a..b91b42ce0bf 100644 --- a/reactos/drivers/filesystems/ext2/src/fastio.c +++ b/reactos/drivers/filesystems/ext2/src/fastio.c @@ -191,9 +191,6 @@ IN PDEVICE_OBJECT DeviceObject) Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { } @@ -257,9 +254,6 @@ IN PDEVICE_OBJECT DeviceObject) Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -321,9 +315,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -384,9 +375,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -452,9 +440,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -519,9 +504,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -582,9 +564,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -646,9 +625,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -931,8 +907,6 @@ void NTAPI Ext2RelLazyWrite( IN PVOID Context) { - BOOLEAN ReturnedStatus = TRUE; - PtrExt2VCB PtrVCB = NULL; PtrExt2FCB PtrFCB = NULL; PtrExt2CCB PtrCCB = NULL; @@ -1105,7 +1079,6 @@ IN BOOLEAN Wait) void NTAPI Ext2RelReadAhead( IN PVOID Context) { - BOOLEAN ReturnedStatus = TRUE; PtrExt2FCB PtrFCB = NULL; PtrExt2CCB PtrCCB = NULL; PtrExt2NTRequiredFCB PtrReqdFCB = NULL; @@ -1211,9 +1184,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -1278,9 +1248,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -1345,9 +1312,6 @@ IN PDEVICE_OBJECT DeviceObject) Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -1411,9 +1375,6 @@ IN PDEVICE_OBJECT DeviceObject) Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -1476,9 +1437,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -1556,9 +1514,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -1621,9 +1576,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -1681,9 +1633,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { @@ -1740,9 +1689,6 @@ IN PDEVICE_OBJECT DeviceObject) RC = Ext2ExceptionHandler(PtrIrpContext, NULL); Ext2LogEvent(EXT2_ERROR_INTERNAL_ERROR, RC); } - - try_exit: NOTHING; - } finally { diff --git a/reactos/drivers/filesystems/ext2/src/fileinfo.c b/reactos/drivers/filesystems/ext2/src/fileinfo.c index 6467caacbad..eba45124074 100644 --- a/reactos/drivers/filesystems/ext2/src/fileinfo.c +++ b/reactos/drivers/filesystems/ext2/src/fileinfo.c @@ -115,7 +115,6 @@ PIRP PtrIrp) BOOLEAN MainResourceAcquired = FALSE; BOOLEAN VCBResourceAcquired = FALSE; BOOLEAN PagingIoResourceAcquired = FALSE; - IO_STATUS_BLOCK LocalIoStatus; void *PtrSystemBuffer = NULL; long BufferLength = 0; FILE_INFORMATION_CLASS FunctionalityRequested; @@ -894,8 +893,6 @@ NTSTATUS NTAPI Ext2SetBasicInformation( { Ext2ClearFlag(PtrFileObject->Flags, FO_TEMPORARY_FILE); } - - try_exit: NOTHING; } finally { diff --git a/reactos/drivers/filesystems/ext2/src/flush.c b/reactos/drivers/filesystems/ext2/src/flush.c index d28b830cd60..ff61c56d126 100644 --- a/reactos/drivers/filesystems/ext2/src/flush.c +++ b/reactos/drivers/filesystems/ext2/src/flush.c @@ -282,8 +282,6 @@ PIRP PtrIrp, PtrExt2VCB PtrVCB) { BOOLEAN AcquiredVCB = FALSE; - PtrExt2FCB PtrFCB = NULL; - PLIST_ENTRY PtrNextFCB = NULL; try { ExAcquireResourceExclusiveLite(&(PtrVCB->VCBResource), TRUE); @@ -335,8 +333,6 @@ PDEVICE_OBJECT PtrDeviceObject, PIRP PtrIrp, PVOID Context) { - NTSTATUS RC = STATUS_SUCCESS; - if (PtrIrp->PendingReturned) { IoMarkIrpPending(PtrIrp); } diff --git a/reactos/drivers/filesystems/ext2/src/fsctrl.c b/reactos/drivers/filesystems/ext2/src/fsctrl.c index a4f204be5ab..372c0c227c3 100644 --- a/reactos/drivers/filesystems/ext2/src/fsctrl.c +++ b/reactos/drivers/filesystems/ext2/src/fsctrl.c @@ -895,8 +895,6 @@ NTSTATUS Ext2UserFileSystemRequest ( DebugTrace(DEBUG_TRACE_FSCTRL, "Unknown FSCTRL !!!", 0); } - - try_exit: NOTHING; } finally { diff --git a/reactos/drivers/filesystems/ext2/src/io.c b/reactos/drivers/filesystems/ext2/src/io.c index 682e0fd5f68..14db465a99f 100644 --- a/reactos/drivers/filesystems/ext2/src/io.c +++ b/reactos/drivers/filesystems/ext2/src/io.c @@ -242,15 +242,7 @@ NTSTATUS NTAPI Ext2PassDownSingleReadWriteIRP( PEXT2_IO_CONTEXT PtrIoContext = NULL; PKEVENT PtrSyncEvent = NULL; - PVOID PtrReadBuffer = NULL; - ULONG ReadBufferLength = 0; - ULONG LogicalBlockNo = 0; - ULONG LogicalBlockSize = 0; - ULONG PhysicalBlockSize = 0; - - uint32 NumberBytesRead = 0; - int i; PIO_STACK_LOCATION PtrIrpNextSp = NULL; try diff --git a/reactos/drivers/filesystems/ext2/src/metadata.c b/reactos/drivers/filesystems/ext2/src/metadata.c index 9614b8e14ab..0b18a2f4d09 100644 --- a/reactos/drivers/filesystems/ext2/src/metadata.c +++ b/reactos/drivers/filesystems/ext2/src/metadata.c @@ -472,8 +472,6 @@ ULONG NTAPI Ext2AllocInode( } } - - try_exit: NOTHING; } finally { @@ -714,8 +712,6 @@ NTSTATUS NTAPI Ext2WriteInode( // The Read Buffer Pointer BYTE * PtrPinnedBuffer = NULL; - PEXT2_INODE PtrTempInode; - // Buffer Control Block PBCB PtrBCB = NULL; @@ -841,7 +837,6 @@ BOOLEAN NTAPI Ext2MakeNewDirectoryEntry( PtrExt2VCB PtrVCB; LARGE_INTEGER VolumeByteOffset; unsigned long LogicalBlockSize = 0; - unsigned long NumberOfBytesToRead = 0; BOOLEAN RC = FALSE; USHORT HeaderLength = sizeof( EXT2_DIR_ENTRY ); @@ -1071,7 +1066,6 @@ BOOLEAN NTAPI Ext2FreeDirectoryEntry( PBCB PtrDataBlockBCB = NULL; BYTE * PtrDataBlock = NULL; PFILE_OBJECT PtrFileObject = NULL; - PEXT2_DIR_ENTRY PtrTempDirEntry; LONGLONG ByteOffset = 0; PtrExt2VCB PtrVCB; LARGE_INTEGER VolumeByteOffset; @@ -2598,9 +2592,6 @@ BOOLEAN NTAPI Ext2IsDirectoryEmpty( BYTE * PtrPinnedBlockBuffer = NULL; PEXT2_DIR_ENTRY PtrDirEntry = NULL; BOOLEAN Found = FALSE; - int i; - - StartBufferOffset.QuadPart = 0; diff --git a/reactos/drivers/filesystems/ext2/src/misc.c b/reactos/drivers/filesystems/ext2/src/misc.c index d5fd68e84f2..bce09f1c029 100644 --- a/reactos/drivers/filesystems/ext2/src/misc.c +++ b/reactos/drivers/filesystems/ext2/src/misc.c @@ -205,9 +205,6 @@ void) DebugTrace( DEBUG_TRACE_FREE, "Freeing = %lX [misc]", Ext2GlobalData.IrpContextZone); ExFreePool(Ext2GlobalData.IrpContextZone); - - try_exit: NOTHING; - } finally { @@ -429,7 +426,7 @@ void) { PtrExt2ObjectName PtrObjectName = NULL; BOOLEAN AllocatedFromZone = TRUE; - KIRQL CurrentIrql; + //KIRQL CurrentIrql; /* // first, try to allocate out of the zone KeAcquireSpinLock(&(Ext2GlobalData.ZoneAllocationSpinLock), &CurrentIrql); @@ -491,7 +488,9 @@ void) void NTAPI Ext2ReleaseObjectName( PtrExt2ObjectName PtrObjectName) { +#ifdef USE_ZONES KIRQL CurrentIrql; +#endif ASSERT(PtrObjectName); PtrObjectName->NodeIdentifier.NodeType = EXT2_NODE_TYPE_FREED; @@ -540,7 +539,9 @@ void) { PtrExt2CCB PtrCCB = NULL; BOOLEAN AllocatedFromZone = TRUE; - KIRQL CurrentIrql; +#ifdef USE_ZONES + KIRQL CurrentIrql; +#endif #ifdef USE_ZONES @@ -608,7 +609,9 @@ void) void NTAPI Ext2ReleaseCCB( PtrExt2CCB PtrCCB) { +#ifdef USE_ZONES KIRQL CurrentIrql; +#endif ASSERT( PtrCCB ); if(PtrCCB->NodeIdentifier.NodeType != EXT2_NODE_TYPE_CCB) @@ -665,7 +668,9 @@ void) { PtrExt2FCB PtrFCB = NULL; BOOLEAN AllocatedFromZone = TRUE; +#ifdef USE_ZONES KIRQL CurrentIrql; +#endif // first, try to allocate out of the zone #ifdef USE_ZONES @@ -862,7 +867,7 @@ PtrExt2ObjectName PtrObjectName) void NTAPI Ext2ReleaseFCB( PtrExt2FCB PtrFCB) { - KIRQL CurrentIrql; + //KIRQL CurrentIrql; AssertFCB( PtrFCB ); @@ -1025,7 +1030,7 @@ PDEVICE_OBJECT PtrTargetDeviceObject) { PtrExt2IrpContext PtrIrpContext = NULL; BOOLEAN AllocatedFromZone = TRUE; - KIRQL CurrentIrql; + //KIRQL CurrentIrql; PIO_STACK_LOCATION PtrIoStackLocation = NULL; /* @@ -1611,8 +1616,6 @@ NTSTATUS NTAPI Ext2GetFCB_CCB_VCB_FromFileObject ( OUT PtrExt2CCB *PPtrCCB, OUT PtrExt2VCB *PPtrVCB ) { - int Offset; - (*PPtrCCB) = (PtrExt2CCB)(PtrFileObject->FsContext2); if( *PPtrCCB ) { diff --git a/reactos/drivers/filesystems/ext2/src/read.c b/reactos/drivers/filesystems/ext2/src/read.c index 1335f09495c..c8f41d34847 100644 --- a/reactos/drivers/filesystems/ext2/src/read.c +++ b/reactos/drivers/filesystems/ext2/src/read.c @@ -117,10 +117,8 @@ BOOLEAN FirstAttempt ) PtrExt2VCB PtrVCB = NULL; PtrExt2NTRequiredFCB PtrReqdFCB = NULL; PERESOURCE PtrResourceAcquired = NULL; - IO_STATUS_BLOCK LocalIoStatus; PVOID PtrSystemBuffer = NULL; PVOID PtrPinnedReadBuffer = NULL; - uint32 KeyValue = 0; BOOLEAN CompleteIrp = TRUE; BOOLEAN PostRequest = FALSE; @@ -129,14 +127,8 @@ BOOLEAN FirstAttempt ) BOOLEAN PagingIo = FALSE; BOOLEAN NonBufferedIo = FALSE; BOOLEAN SynchronousIo = FALSE; - BOOLEAN MdlLocked = FALSE; BOOLEAN ReadTruncated = FALSE; - LARGE_INTEGER StartPhysicalBlock; - ULONG NoOfBlocks = 0; - - PIO_STACK_LOCATION PtrIrpNextSp = NULL; - // Used to cache the Single Indirect blocks pointed to by // the Double Indirect block PEXT2_SIBLOCKS PtrDIArray = NULL; @@ -162,7 +154,7 @@ BOOLEAN FirstAttempt ) PBCB PtrPinnedDIndirectBCB = NULL; PBCB PtrPinnedTIndirectBCB = NULL; - int i, Index; + int Index; try { diff --git a/reactos/drivers/filesystems/ext2/src/shutdown.c b/reactos/drivers/filesystems/ext2/src/shutdown.c index 99833b5550e..0c234a1c7ad 100644 --- a/reactos/drivers/filesystems/ext2/src/shutdown.c +++ b/reactos/drivers/filesystems/ext2/src/shutdown.c @@ -108,7 +108,6 @@ PIRP PtrIrp) { NTSTATUS RC = STATUS_SUCCESS; PIO_STACK_LOCATION PtrIoStackLocation = NULL; - IO_STATUS_BLOCK LocalIoStatus; try { @@ -197,8 +196,6 @@ PIRP PtrIrp) } *///////////////////////////////////////////// - try_exit: NOTHING; - } finally { diff --git a/reactos/drivers/filesystems/ext2/src/volinfo.c b/reactos/drivers/filesystems/ext2/src/volinfo.c index fad3fd8c30c..32661d14a9c 100644 --- a/reactos/drivers/filesystems/ext2/src/volinfo.c +++ b/reactos/drivers/filesystems/ext2/src/volinfo.c @@ -174,7 +174,6 @@ NTSTATUS NTAPI Ext2QueryVolInfo ( Status = STATUS_BUFFER_OVERFLOW; DebugTrace(DEBUG_TRACE_MISC, " === Buffer insufficient", 0); } - try_exit: NOTHING; } finally { diff --git a/reactos/drivers/filesystems/ext2/src/write.c b/reactos/drivers/filesystems/ext2/src/write.c index 154904a263c..63b5ea9b921 100644 --- a/reactos/drivers/filesystems/ext2/src/write.c +++ b/reactos/drivers/filesystems/ext2/src/write.c @@ -113,9 +113,7 @@ NTSTATUS NTAPI Ext2CommonWrite( PtrExt2VCB PtrVCB = NULL; PtrExt2NTRequiredFCB PtrReqdFCB = NULL; PERESOURCE PtrResourceAcquired = NULL; - IO_STATUS_BLOCK LocalIoStatus; void *PtrSystemBuffer = NULL; - uint32 KeyValue = 0; BOOLEAN CompleteIrp = TRUE; BOOLEAN PostRequest = FALSE;