[FASTFAT]

VfatWrite (but not VfatRead) is supposed to return STATUS_INVALID_USER_BUFFER
if an error occurred while locking the buffer.
[KERNEL32]
Reading 0 bytes using ReadFile doesn't always succeed on Windows.


svn path=/trunk/; revision=68620
This commit is contained in:
Aleksandar Andrejevic 2015-08-07 23:48:54 +00:00
parent b6956aa369
commit d1c5a86965
2 changed files with 1 additions and 1 deletions

View file

@ -131,7 +131,6 @@ ReadFile(IN HANDLE hFile,
TRACE("ReadFile(hFile %p)\n", hFile); TRACE("ReadFile(hFile %p)\n", hFile);
if (lpNumberOfBytesRead != NULL) *lpNumberOfBytesRead = 0; if (lpNumberOfBytesRead != NULL) *lpNumberOfBytesRead = 0;
if (!nNumberOfBytesToRead) return TRUE;
hFile = TranslateStdHandle(hFile); hFile = TranslateStdHandle(hFile);

View file

@ -924,6 +924,7 @@ VfatWrite(
Status = VfatLockUserBuffer(IrpContext->Irp, Length, IoReadAccess); Status = VfatLockUserBuffer(IrpContext->Irp, Length, IoReadAccess);
if (!NT_SUCCESS(Status)) if (!NT_SUCCESS(Status))
{ {
Status = STATUS_INVALID_USER_BUFFER;
goto ByeBye; goto ByeBye;
} }