mirror of
https://github.com/reactos/reactos.git
synced 2025-07-05 16:31:23 +00:00
[NtUser]
- Fix timeout for send messages. - Assert if not the same thread while dispatching messages. svn path=/trunk/; revision=65522
This commit is contained in:
parent
b085d814b6
commit
c0851ad2a3
1 changed files with 6 additions and 3 deletions
|
@ -2,7 +2,7 @@
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS Win32k subsystem
|
* PROJECT: ReactOS Win32k subsystem
|
||||||
* PURPOSE: Message queues
|
* PURPOSE: Message queues
|
||||||
* FILE: subsystems/win32/win32k/ntuser/msgqueue.c
|
* FILE: win32ss/user/ntuser/msgqueue.c
|
||||||
* PROGRAMER: Casper S. Hornstrup (chorns@users.sourceforge.net)
|
* PROGRAMER: Casper S. Hornstrup (chorns@users.sourceforge.net)
|
||||||
Alexandre Julliard
|
Alexandre Julliard
|
||||||
Maarten Lankhorst
|
Maarten Lankhorst
|
||||||
|
@ -751,6 +751,8 @@ co_MsqDispatchOneSentMessage(PTHREADINFO pti)
|
||||||
BOOL Ret;
|
BOOL Ret;
|
||||||
LRESULT Result = 0;
|
LRESULT Result = 0;
|
||||||
|
|
||||||
|
ASSERT(pti == PsGetCurrentThreadWin32Thread());
|
||||||
|
|
||||||
if (IsListEmpty(&pti->SentMessagesListHead))
|
if (IsListEmpty(&pti->SentMessagesListHead))
|
||||||
{
|
{
|
||||||
return(FALSE);
|
return(FALSE);
|
||||||
|
@ -1098,7 +1100,8 @@ co_MsqSendMessage(PTHREADINFO ptirec,
|
||||||
|
|
||||||
KeInitializeEvent(&CompletionEvent, NotificationEvent, FALSE);
|
KeInitializeEvent(&CompletionEvent, NotificationEvent, FALSE);
|
||||||
|
|
||||||
Timeout.QuadPart = (LONGLONG) uTimeout * (LONGLONG) -10000;
|
Timeout.QuadPart = Int32x32To64(-10000,uTimeout); // Pass SMTO test with a TO of 0x80000000.
|
||||||
|
TRACE("Timeout val %lld\n",Timeout.QuadPart)
|
||||||
|
|
||||||
/* FIXME: Increase reference counter of sender's message queue here */
|
/* FIXME: Increase reference counter of sender's message queue here */
|
||||||
|
|
||||||
|
@ -1181,7 +1184,7 @@ co_MsqSendMessage(PTHREADINFO ptirec,
|
||||||
|
|
||||||
TRACE("MsqSendMessage (blocked) timed out 1\n");
|
TRACE("MsqSendMessage (blocked) timed out 1\n");
|
||||||
}
|
}
|
||||||
while (co_MsqDispatchOneSentMessage(ptirec))
|
while (co_MsqDispatchOneSentMessage(pti))
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue