user32: Always start the 64-bit version of wineboot.exe on Wow64.

This commit is contained in:
Alexandre Julliard 2010-03-29 15:48:25 +02:00
parent 3397a8b44b
commit bb0c660ed0
1 changed files with 4 additions and 0 deletions

View File

@ -357,6 +357,7 @@ BOOL WINAPI ExitWindowsEx( UINT flags, DWORD reason )
WCHAR cmdline[MAX_PATH + 64]; WCHAR cmdline[MAX_PATH + 64];
PROCESS_INFORMATION pi; PROCESS_INFORMATION pi;
STARTUPINFOW si; STARTUPINFOW si;
void *redir;
GetSystemDirectoryW( app, MAX_PATH - sizeof(winebootW)/sizeof(WCHAR) ); GetSystemDirectoryW( app, MAX_PATH - sizeof(winebootW)/sizeof(WCHAR) );
strcatW( app, winebootW ); strcatW( app, winebootW );
@ -372,11 +373,14 @@ BOOL WINAPI ExitWindowsEx( UINT flags, DWORD reason )
memset( &si, 0, sizeof si ); memset( &si, 0, sizeof si );
si.cb = sizeof si; si.cb = sizeof si;
Wow64DisableWow64FsRedirection( &redir );
if (!CreateProcessW( app, cmdline, NULL, NULL, FALSE, DETACHED_PROCESS, NULL, NULL, &si, &pi )) if (!CreateProcessW( app, cmdline, NULL, NULL, FALSE, DETACHED_PROCESS, NULL, NULL, &si, &pi ))
{ {
Wow64RevertWow64FsRedirection( redir );
ERR( "Failed to run %s\n", debugstr_w(cmdline) ); ERR( "Failed to run %s\n", debugstr_w(cmdline) );
return FALSE; return FALSE;
} }
Wow64RevertWow64FsRedirection( redir );
CloseHandle( pi.hProcess ); CloseHandle( pi.hProcess );
CloseHandle( pi.hThread ); CloseHandle( pi.hThread );
return TRUE; return TRUE;