Commit b4b817b9 authored by Alexandre Julliard's avatar Alexandre Julliard

user32: Only wait for the desktop process when necessary.

parent 82b38139
......@@ -57,8 +57,15 @@ static HMODULE load_desktop_driver( HWND hwnd )
WCHAR key[(sizeof(key_pathW) + sizeof(displayW)) / sizeof(WCHAR) + 40];
UINT guid_atom = HandleToULong( GetPropW( hwnd, display_device_guid_propW ));
USER_CheckNotLock();
strcpy( driver_load_error, "The explorer process failed to start." ); /* default error */
if (!guid_atom)
{
SendMessageW( hwnd, WM_NULL, 0, 0 ); /* wait for the desktop process to be ready */
guid_atom = HandleToULong( GetPropW( hwnd, display_device_guid_propW ));
}
memcpy( key, key_pathW, sizeof(key_pathW) );
if (!GlobalGetAtomNameW( guid_atom, key + strlenW(key), 40 )) return 0;
strcatW( key, displayW );
......
......@@ -2086,9 +2086,6 @@ HWND WINAPI GetDesktopWindow(void)
SERVER_END_REQ;
}
/* wait for the desktop process to be ready */
SendMessageW( thread_info->top_window, WM_NULL, 0, 0 );
if (!thread_info->top_window || !USER_Driver->pCreateDesktopWindow( thread_info->top_window ))
ERR( "failed to create desktop window\n" );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment