ntdll: NtReadFile should fail for overlapped IO on files if offset is negative.
This commit is contained in:
parent
b314a25320
commit
eb10471bac
|
@ -606,7 +606,7 @@ NTSTATUS WINAPI NtReadFile(HANDLE hFile, HANDLE hEvent,
|
|||
|
||||
if (type == FD_TYPE_FILE)
|
||||
{
|
||||
if (!(options & (FILE_SYNCHRONOUS_IO_ALERT | FILE_SYNCHRONOUS_IO_NONALERT)) && !offset)
|
||||
if (!(options & (FILE_SYNCHRONOUS_IO_ALERT | FILE_SYNCHRONOUS_IO_NONALERT)) && (!offset || offset->QuadPart < 0))
|
||||
{
|
||||
status = STATUS_INVALID_PARAMETER;
|
||||
goto done;
|
||||
|
|
Loading…
Reference in New Issue