[ros-diffs] [cfinck] 33547: Make 100% sure that the correct "regedit.exe" is launched by using GetWindowsDirectory and appending "\regedit.exe" as suggested by Alex on ros-dev.
cfinck at svn.reactos.org
cfinck at svn.reactos.org
Sat May 17 11:39:37 CEST 2008
Author: cfinck
Date: Sat May 17 04:39:36 2008
New Revision: 33547
URL: http://svn.reactos.org/svn/reactos?rev=33547&view=rev
Log:
Make 100% sure that the correct "regedit.exe" is launched by using GetWindowsDirectory and appending "\regedit.exe" as suggested by Alex on ros-dev.
Modified:
trunk/reactos/base/applications/regedt32/regedt32.c
Modified: trunk/reactos/base/applications/regedt32/regedt32.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/regedt32/regedt32.c?rev=33547&r1=33546&r2=33547&view=diff
==============================================================================
--- trunk/reactos/base/applications/regedt32/regedt32.c [iso-8859-1] (original)
+++ trunk/reactos/base/applications/regedt32/regedt32.c [iso-8859-1] Sat May 17 04:39:36 2008
@@ -5,7 +5,12 @@
int WINAPI _tWinMain(HINSTANCE hCurInst, HINSTANCE hPrevInst,
LPTSTR lpsCmdLine, int nCmdShow)
{
- ShellExecute(NULL, NULL, _T("regedit.exe"), lpsCmdLine, NULL, nCmdShow);
+ TCHAR szPath[MAX_PATH];
+
+ GetWindowsDirectory(szPath, MAX_PATH);
+ _tcscat(szPath, _T("\\regedit.exe"));
+
+ ShellExecute(NULL, NULL, szPath, lpsCmdLine, NULL, nCmdShow);
return 0;
}
More information about the Ros-diffs
mailing list