error msg on bad call

svn path=/trunk/; revision=38994
This commit is contained in:
Christoph von Wittich 2009-01-21 13:27:18 +00:00
parent ea36a66139
commit d4835adc0b

View file

@ -132,6 +132,10 @@ DeviceIoControl(IN HANDLE hDevice,
/* lpBytesReturned must not be NULL here, in fact Win doesn't
check that case either and crashes (only after the operation
completed) */
if (!lpBytesReturned)
{
ERR("Bad caller: lpBytesReturned must not be NULL");
}
*lpBytesReturned = Iosb.Information;
}
else
@ -184,6 +188,10 @@ GetOverlappedResult (
}
}
if (!lpNumberOfBytesTransferred)
{
ERR("Bad caller: lpNumberOfBytesTransferred must not be NULL");
}
*lpNumberOfBytesTransferred = lpOverlapped->InternalHigh;
if (!NT_SUCCESS(lpOverlapped->Internal))