mirror of
https://github.com/VincentWei/MiniGUI.git
synced 2026-09-24 09:14:09 +08:00
cleanup
This commit is contained in:
@@ -3529,6 +3529,7 @@ void GUIAPI MainWindowThreadCleanup (HWND hMainWnd)
|
||||
#ifdef _MGRM_THREADS
|
||||
if (pWin->pHosting == NULL) {
|
||||
mg_FreeMsgQueueThisThread ();
|
||||
_MG_PRINTF ("GUI>Window: Message queure is freed: %p (%s)\n", pWin, pWin->spCaption);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
@@ -599,7 +599,7 @@ static inline MSGQUEUE* GetMsgQueueThisThread (void)
|
||||
pMsgQueue = (MSGQUEUE*) pthread_getspecific (__mg_threadinfo_key);
|
||||
#ifdef __VXWORKS__
|
||||
if (pMsgQueue == (void *)-1) {
|
||||
return NULL;
|
||||
return NULL;
|
||||
}
|
||||
#endif
|
||||
return pMsgQueue;
|
||||
|
||||
@@ -485,8 +485,10 @@ BOOL PeekMessageEx (PMSG pMsg, HWND hWnd, UINT nMsgFilterMin, UINT nMsgFilterMax
|
||||
return FALSE;
|
||||
|
||||
#ifdef _MGRM_THREADS
|
||||
if (!(pMsgQueue = GetMsgQueueThisThread ()))
|
||||
if (!(pMsgQueue = GetMsgQueueThisThread ())) {
|
||||
_MG_PRINTF ("Kernel>message: no message queue.\n");
|
||||
return FALSE;
|
||||
}
|
||||
#else
|
||||
pMsgQueue = __mg_dsk_msg_queue;
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user