mirror of
https://github.com/reactos/reactos.git
synced 2024-10-05 17:06:29 +00:00
[WIN32K]
Do not go beyond the MouseHistoryOfMoves[] bounds. Fixes a crash in Win32k. svn path=/trunk/; revision=52887
This commit is contained in:
parent
21b5c3a4ec
commit
98e48b5a92
|
@ -616,7 +616,8 @@ co_MsqInsertMouseMessage(MSG* Msg, DWORD flags, ULONG_PTR dwExtraInfo, BOOL Hook
|
|||
MouseHistoryOfMoves[gcur_count].y = Msg->pt.y;
|
||||
MouseHistoryOfMoves[gcur_count].time = Msg->time;
|
||||
MouseHistoryOfMoves[gcur_count].dwExtraInfo = dwExtraInfo;
|
||||
if (gcur_count++ == 64) gcur_count = 0; // 0 - 63 is 64, FIFO forwards.
|
||||
if (++gcur_count == ARRAYSIZE(MouseHistoryOfMoves))
|
||||
gcur_count = 0; // 0 - 63 is 64, FIFO forwards.
|
||||
}
|
||||
|
||||
//
|
||||
|
|
Loading…
Reference in a new issue