mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-02 12:23:31 +00:00
* dlls/shell32/shellpath.c: Aric Stewart <[email protected]>
Make sure that the size of the buffer passed to RegSetValueExW is in bytes not WCHARs. svn path=/trunk/; revision=10291
This commit is contained in:
@@ -1101,6 +1101,7 @@ HRESULT WINAPI SHGetFolderPathW(
|
||||
|
||||
if (RegQueryValueExW(hKey,szValueName,NULL,&dwType,(LPBYTE)pszPath,&dwPathLen))
|
||||
{
|
||||
|
||||
/* value not existing */
|
||||
if (dwCsidlFlags & CSIDL_MYFLAG_RELATIVE)
|
||||
{
|
||||
@@ -1114,7 +1115,8 @@ HRESULT WINAPI SHGetFolderPathW(
|
||||
strcpyW(pszPath + 3, szDefaultPath);
|
||||
}
|
||||
dwType=REG_SZ;
|
||||
RegSetValueExW(hKey,szValueName,0,REG_SZ,(LPBYTE)pszPath,strlenW(pszPath)+1);
|
||||
RegSetValueExW(hKey,szValueName,0,REG_SZ,(LPBYTE)pszPath,
|
||||
(strlenW(pszPath)+1)*sizeof(WCHAR));
|
||||
}
|
||||
}
|
||||
RegCloseKey(hKey);
|
||||
@@ -1150,7 +1152,8 @@ HRESULT WINAPI SHGetFolderPathW(
|
||||
strcpyW(pszPath + 3, szDefaultPath);
|
||||
}
|
||||
dwType=REG_SZ;
|
||||
RegSetValueExW(hKey,szValueName,0,REG_SZ,(LPBYTE)pszPath,strlenW(pszPath)+1);
|
||||
RegSetValueExW(hKey,szValueName,0,REG_SZ,(LPBYTE)pszPath,
|
||||
(strlenW(pszPath)+1)*sizeof(WCHAR));
|
||||
}
|
||||
RegCloseKey(hKey);
|
||||
}
|
||||
@@ -1322,14 +1325,14 @@ HRESULT WINAPI SHGetSpecialFolderLocation(
|
||||
*ppidl = _ILCreateControlPanel();
|
||||
break;
|
||||
|
||||
case CSIDL_FONTS:
|
||||
FIXME("virtual font folder");
|
||||
break;
|
||||
|
||||
case CSIDL_PRINTERS:
|
||||
*ppidl = _ILCreatePrinters();
|
||||
break;
|
||||
|
||||
case CSIDL_FONTS:
|
||||
FIXME("virtual font folder");
|
||||
break;
|
||||
|
||||
case CSIDL_BITBUCKET:
|
||||
*ppidl = _ILCreateBitBucket();
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user