winedos: Make sure that the main message queue exists before the DOS thread starts.

This commit is contained in:
Alexandre Julliard 2008-05-07 17:33:19 +02:00
parent 279acf6a8a
commit f334c0fbba
1 changed files with 4 additions and 0 deletions

View File

@ -655,6 +655,7 @@ static void MZ_Launch( LPCSTR cmdtail, int length )
BYTE *psp_start = PTR_REAL_TO_LIN( DOSVM_psp, 0 );
DWORD rv;
SYSLEVEL *lock;
MSG msg;
MZ_FillPSP(psp_start, cmdtail, length);
pTask->flags |= TDBF_WINOLDAP;
@ -665,6 +666,9 @@ static void MZ_Launch( LPCSTR cmdtail, int length )
GetpWin16Lock( &lock );
_LeaveSysLevel( lock );
/* force the message queue to be created */
PeekMessageW(&msg, NULL, WM_USER, WM_USER, PM_NOREMOVE);
ResumeThread(dosvm_thread);
rv = DOSVM_Loop(dosvm_thread);