mirror of
https://github.com/reactos/reactos.git
synced 2024-07-04 11:44:33 +00:00
Copy correct number of bytes
svn path=/trunk/; revision=12850
This commit is contained in:
parent
5ccc6ee89d
commit
f31ecfbd4a
|
@ -1,5 +1,4 @@
|
||||||
/* $Id: message.c,v 1.49 2004/12/30 02:32:26 navaraf Exp $
|
/*
|
||||||
*
|
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS user32.dll
|
* PROJECT: ReactOS user32.dll
|
||||||
* FILE: lib/user32/windows/message.c
|
* FILE: lib/user32/windows/message.c
|
||||||
|
@ -2038,7 +2037,7 @@ RealMsgWaitForMultipleObjectsEx(
|
||||||
LPHANDLE RealHandles;
|
LPHANDLE RealHandles;
|
||||||
HANDLE MessageQueueHandle;
|
HANDLE MessageQueueHandle;
|
||||||
DWORD Result;
|
DWORD Result;
|
||||||
|
|
||||||
if (dwFlags & ~(MWMO_WAITALL | MWMO_ALERTABLE | MWMO_INPUTAVAILABLE))
|
if (dwFlags & ~(MWMO_WAITALL | MWMO_ALERTABLE | MWMO_INPUTAVAILABLE))
|
||||||
{
|
{
|
||||||
SetLastError(ERROR_INVALID_PARAMETER);
|
SetLastError(ERROR_INVALID_PARAMETER);
|
||||||
|
@ -2067,7 +2066,7 @@ RealMsgWaitForMultipleObjectsEx(
|
||||||
return WAIT_FAILED;
|
return WAIT_FAILED;
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlCopyMemory(RealHandles, pHandles, nCount);
|
RtlCopyMemory(RealHandles, pHandles, nCount * sizeof(HANDLE));
|
||||||
RealHandles[nCount] = MessageQueueHandle;
|
RealHandles[nCount] = MessageQueueHandle;
|
||||||
|
|
||||||
Result = WaitForMultipleObjectsEx(nCount + 1, RealHandles,
|
Result = WaitForMultipleObjectsEx(nCount + 1, RealHandles,
|
||||||
|
|
Loading…
Reference in a new issue