mirror of
https://github.com/reactos/reactos.git
synced 2024-08-13 06:37:06 +00:00
[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. svn path=/trunk/; revision=56865
This commit is contained in:
parent
3b69ad47bf
commit
1963b7a4e6
|
@ -364,6 +364,7 @@ static BOOL ProcessRunKeys(HKEY hkRoot, LPCWSTR szKeyName, BOOL bDelete,
|
||||||
{
|
{
|
||||||
DWORD nValLength=nMaxValue, nDataLength=nMaxCmdLine;
|
DWORD nValLength=nMaxValue, nDataLength=nMaxCmdLine;
|
||||||
DWORD type;
|
DWORD type;
|
||||||
|
WCHAR szCmdLineExp[MAX_PATH+1]= L"\0";
|
||||||
|
|
||||||
--i;
|
--i;
|
||||||
|
|
||||||
|
@ -390,7 +391,8 @@ static BOOL ProcessRunKeys(HKEY hkRoot, LPCWSTR szKeyName, BOOL bDelete,
|
||||||
continue;
|
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());
|
printf("Error running cmd #%ld (%ld)\n", i, GetLastError());
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue