Alexandre Julliard : user32: Run the explorer process from the system directory.

Alexandre Julliard julliard at winehq.org
Thu Aug 20 12:59:11 CDT 2009


Module: wine
Branch: master
Commit: e3b395ff2ceac3749778f466c2c9752898dd5010
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=e3b395ff2ceac3749778f466c2c9752898dd5010

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Thu Aug 20 17:14:48 2009 +0200

user32: Run the explorer process from the system directory.

---

 dlls/user32/win.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/dlls/user32/win.c b/dlls/user32/win.c
index da196ed..44b15b1 100644
--- a/dlls/user32/win.c
+++ b/dlls/user32/win.c
@@ -1785,6 +1785,7 @@ HWND WINAPI GetDesktopWindow(void)
             static const WCHAR command_line[] = {'\\','e','x','p','l','o','r','e','r','.','e','x','e',' ','/','d','e','s','k','t','o','p',0};
             STARTUPINFOW si;
             PROCESS_INFORMATION pi;
+            WCHAR systemdir[MAX_PATH];
             WCHAR cmdline[MAX_PATH + sizeof(command_line)/sizeof(WCHAR)];
 
             memset( &si, 0, sizeof(si) );
@@ -1794,10 +1795,11 @@ HWND WINAPI GetDesktopWindow(void)
             si.hStdOutput = 0;
             si.hStdError  = GetStdHandle( STD_ERROR_HANDLE );
 
-            GetSystemDirectoryW( cmdline, MAX_PATH );
+            GetSystemDirectoryW( systemdir, MAX_PATH );
+            lstrcpyW( cmdline, systemdir );
             lstrcatW( cmdline, command_line );
             if (CreateProcessW( NULL, cmdline, NULL, NULL, FALSE, DETACHED_PROCESS,
-                                NULL, NULL, &si, &pi ))
+                                NULL, systemdir, &si, &pi ))
             {
                 TRACE( "started explorer pid %04x tid %04x\n", pi.dwProcessId, pi.dwThreadId );
                 WaitForInputIdle( pi.hProcess, 10000 );




More information about the wine-cvs mailing list