It's no longer needed, and recent Windows versions don't have it either.
Signed-off-by: Dmitry Timoshkov dmitry@baikal.ru --- dlls/shell32/shellpath.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-)
diff --git a/dlls/shell32/shellpath.c b/dlls/shell32/shellpath.c index de4bf7d566..37e5a13b77 100644 --- a/dlls/shell32/shellpath.c +++ b/dlls/shell32/shellpath.c @@ -957,7 +957,6 @@ static const WCHAR ProgramDataVarW[] = {'%','P','r','o','g','r','a','m','D','a', static const WCHAR SystemDriveW[] = {'%','S','y','s','t','e','m','D','r','i','v','e','%','\0'}; static const WCHAR ProfileListW[] = {'S','o','f','t','w','a','r','e','\','M','i','c','r','o','s','o','f','t','\','W','i','n','d','o','w','s',' ','N','T','\','C','u','r','r','e','n','t','V','e','r','s','i','o','n','\','P','r','o','f','i','l','e','L','i','s','t',0}; static const WCHAR ProfilesDirectoryW[] = {'P','r','o','f','i','l','e','s','D','i','r','e','c','t','o','r','y',0}; -static const WCHAR AllUsersProfileValueW[] = {'A','l','l','U','s','e','r','s','P','r','o','f','i','l','e','\0'}; static const WCHAR szSHFolders[] = {'S','o','f','t','w','a','r','e','\','M','i','c','r','o','s','o','f','t','\','W','i','n','d','o','w','s','\','C','u','r','r','e','n','t','V','e','r','s','i','o','n','\','E','x','p','l','o','r','e','r','\','S','h','e','l','l',' ','F','o','l','d','e','r','s','\0'}; static const WCHAR szSHUserFolders[] = {'S','o','f','t','w','a','r','e','\','M','i','c','r','o','s','o','f','t','\','W','i','n','d','o','w','s','\','C','u','r','r','e','n','t','V','e','r','s','i','o','n','\','E','x','p','l','o','r','e','r','\','U','s','e','r',' ','S','h','e','l','l',' ','F','o','l','d','e','r','s','\0'}; static const WCHAR szDefaultProfileDirW[] = {'u','s','e','r','s',0}; @@ -3804,17 +3803,8 @@ static HRESULT _SHExpandEnvironmentStrings(LPCWSTR szSrc, LPWSTR szDest) strcpyW(szTemp, szSrc); while (SUCCEEDED(hr) && szTemp[0] == '%') { - if (!strncmpiW(szTemp, AllUsersProfileW, strlenW(AllUsersProfileW))) - { - WCHAR szAllUsers[MAX_PATH]; - - strcpyW(szDest, szProfilesPrefix); - hr = _SHGetProfilesValue(key, AllUsersProfileValueW, - szAllUsers, AllUsersW); - PathAppendW(szDest, szAllUsers); - PathAppendW(szDest, szTemp + strlenW(AllUsersProfileW)); - } - else if (!strncmpiW(szTemp, ProgramDataVarW, strlenW(ProgramDataVarW))) + if (!strncmpiW(szTemp, AllUsersProfileW, strlenW(AllUsersProfileW)) || + !strncmpiW(szTemp, ProgramDataVarW, strlenW(ProgramDataVarW))) { WCHAR szProgramData[MAX_PATH], def_val[MAX_PATH]; HKEY shellFolderKey;
Dmitry Timoshkov dmitry@baikal.ru writes:
It's no longer needed, and recent Windows versions don't have it either.
Signed-off-by: Dmitry Timoshkov dmitry@baikal.ru
dlls/shell32/shellpath.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-)
This breaks variable expansion, since the strings don't have the same length:
"Common Desktop"="C:\ProgramData\ILE%\Desktop"