Author: fireball Date: Tue Jul 10 22:48:23 2012 New Revision: 56865
URL: http://svn.reactos.org/svn/reactos?rev=56865&view=rev Log: [EXPLORER] - Edijs Kolesnikovics: Expand environment strings during processing startup items in HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run. See issue #6053 for more details.
Modified: trunk/reactos/base/shell/explorer/services/startup.c
Modified: trunk/reactos/base/shell/explorer/services/startup.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/explorer/service... ============================================================================== --- trunk/reactos/base/shell/explorer/services/startup.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/explorer/services/startup.c [iso-8859-1] Tue Jul 10 22:48:23 2012 @@ -364,6 +364,7 @@ { DWORD nValLength=nMaxValue, nDataLength=nMaxCmdLine; DWORD type; + WCHAR szCmdLineExp[MAX_PATH+1]= L"\0";
--i;
@@ -390,7 +391,8 @@ continue; }
- if ((res=runCmd(szCmdLine, NULL, bSynchronous, FALSE))==INVALID_RUNCMD_RETURN) + ExpandEnvironmentStrings(szCmdLine, szCmdLineExp, sizeof(szCmdLineExp)); + if ((res=runCmd(szCmdLineExp, NULL, bSynchronous, FALSE))==INVALID_RUNCMD_RETURN) { printf("Error running cmd #%ld (%ld)\n", i, GetLastError()); }