diff --git a/NTOSKRNL/CC/cclazywriter.cpp b/NTOSKRNL/CC/cclazywriter.cpp index 877bd0d..33035ab 100644 --- a/NTOSKRNL/CC/cclazywriter.cpp +++ b/NTOSKRNL/CC/cclazywriter.cpp @@ -474,13 +474,13 @@ NTAPI CcSetValidData(IN PFILE_OBJECT FileObject, IN PLARGE_INTEGER FileSize) { - FILE_END_OF_FILE_INFORMATION FileInfo; // Structure to hold end-of-file information - PDEVICE_OBJECT DeviceObject; // Pointer to the device object associated with the file - PIO_STACK_LOCATION IoStack; // Pointer to an I/O stack location structure - IO_STATUS_BLOCK IoStatus; // I/O status block structure - KEVENT Event; // Kernel event object for synchronization - PIRP Irp; // Pointer to an I/O request packet structure - NTSTATUS Status; // Status of the operation + FILE_END_OF_FILE_INFORMATION FileInfo = {0}; + PDEVICE_OBJECT DeviceObject = nullptr; + PIO_STACK_LOCATION IoStack = nullptr; + IO_STATUS_BLOCK IoStatus = nullptr; + KEVENT Event; + PIRP Irp; + NTSTATUS Status; /*Initialize a kernel event object for synchronization */ KeInitializeEvent(&Event, NotificationEvent, FALSE); @@ -984,9 +984,9 @@ NTAPI CcLazyWriteScan() NTSTATUS CcWaitForCurrentLazyWriterActivity() { NTSTATUS result; - PWORK_QUEUE_ENTRY WorkQueueEntry; - KEVENT Event; - KIRQL irql; + PWORK_QUEUE_ENTRY WorkQueueEntry = nullptr; + KEVENT Event = {0}; + KIRQL irql = {0}; result = CcAllocateWorkQueueEntry(&WorkQueueEntry); if (NT_SUCCESS(result)) @@ -1030,7 +1030,7 @@ CcWorkerThread(PVOID Parameter) PWORK_QUEUE_ENTRY WorkEntry = nullptr; PLIST_ENTRY Entry = nullptr; PKPRCB Prcb = nullptr; - IO_STATUS_BLOCK IoStatus = {}; + IO_STATUS_BLOCK IoStatus = {0}; KIRQL OldIrql = PASSIVE_LEVEL; BOOLEAN DropThrottle = FALSE; BOOLEAN WritePerformed = FALSE; @@ -1246,13 +1246,13 @@ CcAllocateWorkQueueEntry(PWORK_QUEUE_ENTRY &workQueueEntry) NTSTATUS CcWaitForCurrentLazyWriterActivity() { - NTSTATUS status; // Status of the operation - PWORK_QUEUE_ENTRY workQueueEntry; // Work queue entry - PLIST_ENTRY blink; - KIRQL irql; - KEVENT event; // Event object + NTSTATUS status; + PWORK_QUEUE_ENTRY workQueueEntry = nullptr; + PLIST_ENTRY blink = nullptr; + KIRQL irql = PASSIVE_LEVEL; + KEVENT event = {0}; - // Allocate a work queue entry + /* Allocate a work queue entry*/ status = CcAllocateWorkQueueEntry(&workQueueEntry); if (NT_SUCCESS(status)) // Check if the status is a success {