Skip to content

Commit 65f9783

Browse files
committed
[NTOSKRNL] Properly initialize the IO_STATUS_BLOCK
1 parent abf9340 commit 65f9783

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

ntoskrnl/fsrtl/fastio.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -310,11 +310,13 @@ FsRtlCopyWrite(IN PFILE_OBJECT FileObject,
310310
return FALSE;
311311
}
312312

313+
/* Already init IO_STATUS_BLOCK */
314+
IoStatus->Status = STATUS_SUCCESS;
315+
IoStatus->Information = Length;
316+
313317
/* No actual read */
314318
if (!Length)
315319
{
316-
IoStatus->Status = STATUS_SUCCESS;
317-
IoStatus->Information = Length;
318320
return TRUE;
319321
}
320322

0 commit comments

Comments
 (0)