Initialize list entry after removing a message from DispatchingMessagesHead. Fixes list corruption.
CORE-9357 #resolve

svn path=/trunk/; revision=66685
This commit is contained in:
Timo Kreuzer 2015-03-14 11:22:31 +00:00
parent 11164521c3
commit e4ce29c7c6
2 changed files with 1 additions and 1 deletions

View file

@ -1699,7 +1699,6 @@ co_IntSendMessageWithCallBack( HWND hWnd,
Message->ptiSender = NULL; // mjmartin, you are right! This is null.
Message->ptiCallBackSender = Win32Thread;
InitializeListHead(&Message->DispatchingListEntry);
//Message->DispatchingListEntry.Flink = NULL;
Message->CompletionCallback = CompletionCallback;
Message->CompletionCallbackContext = CompletionCallbackContext;
Message->HookMessage = MSQ_NORMAL;

View file

@ -2128,6 +2128,7 @@ MsqCleanupThreadMsgs(PTHREADINFO pti)
{
CurrentEntry = RemoveHeadList(&pti->DispatchingMessagesHead);
CurrentSentMessage = CONTAINING_RECORD(CurrentEntry, USER_SENT_MESSAGE, DispatchingListEntry);
InitializeListHead(&CurrentSentMessage->DispatchingListEntry);
CurrentSentMessage->CompletionEvent = NULL;
CurrentSentMessage->Result = NULL;