mirror of
https://github.com/reactos/reactos.git
synced 2025-01-02 12:32:47 +00:00
Fix external termination of thread while thread is waiting in GetMessage()
svn path=/trunk/; revision=10830
This commit is contained in:
parent
eed6b713aa
commit
d77482d763
2 changed files with 8 additions and 8 deletions
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: message.c,v 1.72 2004/08/26 12:29:37 gvg Exp $
|
/* $Id: message.c,v 1.73 2004/09/12 19:29:22 gvg Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -855,7 +855,7 @@ IntWaitMessage(HWND Wnd,
|
||||||
/* Nothing found. Wait for new messages. */
|
/* Nothing found. Wait for new messages. */
|
||||||
Status = MsqWaitForNewMessages(ThreadQueue);
|
Status = MsqWaitForNewMessages(ThreadQueue);
|
||||||
}
|
}
|
||||||
while (STATUS_WAIT_0 <= STATUS_WAIT_0 && Status <= STATUS_WAIT_63);
|
while (STATUS_WAIT_0 <= Status && Status <= STATUS_WAIT_63);
|
||||||
|
|
||||||
SetLastNtError(Status);
|
SetLastNtError(Status);
|
||||||
|
|
||||||
|
@ -953,9 +953,9 @@ NtUserGetMessage(PNTUSERGETMESSAGEINFO UnsafeInfo,
|
||||||
return (BOOL) -1;
|
return (BOOL) -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else if (! IntWaitMessage(Wnd, MsgFilterMin, MsgFilterMax))
|
||||||
{
|
{
|
||||||
IntWaitMessage(Wnd, MsgFilterMin, MsgFilterMax);
|
return (BOOL) -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
while (! GotMessage);
|
while (! GotMessage);
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: msgqueue.c,v 1.105 2004/08/28 15:01:46 gvg Exp $
|
/* $Id: msgqueue.c,v 1.106 2004/09/12 19:29:23 gvg Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -425,7 +425,7 @@ MsqPeekHardwareMessage(PUSER_MESSAGE_QUEUE MessageQueue, HWND hWnd,
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
WaitStatus = KeWaitForMultipleObjects(2, WaitObjects, WaitAny, UserRequest,
|
WaitStatus = KeWaitForMultipleObjects(2, WaitObjects, WaitAny, UserRequest,
|
||||||
UserMode, TRUE, NULL, NULL);
|
UserMode, FALSE, NULL, NULL);
|
||||||
while (MsqDispatchOneSentMessage(MessageQueue))
|
while (MsqDispatchOneSentMessage(MessageQueue))
|
||||||
{
|
{
|
||||||
;
|
;
|
||||||
|
@ -1091,7 +1091,7 @@ MsqWaitForNewMessages(PUSER_MESSAGE_QUEUE MessageQueue)
|
||||||
WaitAny,
|
WaitAny,
|
||||||
Executive,
|
Executive,
|
||||||
UserMode,
|
UserMode,
|
||||||
TRUE,
|
FALSE,
|
||||||
NULL,
|
NULL,
|
||||||
NULL));
|
NULL));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue