Commit 5c8e83c4 authored by Huw Davies's avatar Huw Davies Committed by Alexandre Julliard

user32: If the value doesn't exist under the volatile key fallback to the permanent key.

parent fb5dbd60
...@@ -622,12 +622,19 @@ static BOOL SYSPARAMS_LoadRaw( LPCWSTR lpRegKey, LPCWSTR lpValName, LPBYTE lpBuf ...@@ -622,12 +622,19 @@ static BOOL SYSPARAMS_LoadRaw( LPCWSTR lpRegKey, LPCWSTR lpValName, LPBYTE lpBuf
HKEY hKey; HKEY hKey;
memset( lpBuf, 0, count ); memset( lpBuf, 0, count );
if ((RegOpenKeyW( get_volatile_regkey(), lpRegKey, &hKey ) == ERROR_SUCCESS) ||
(RegOpenKeyW( HKEY_CURRENT_USER, lpRegKey, &hKey ) == ERROR_SUCCESS)) if (RegOpenKeyW( get_volatile_regkey(), lpRegKey, &hKey ) == ERROR_SUCCESS)
{
ret = !RegQueryValueExW( hKey, lpValName, NULL, &type, lpBuf, &count );
RegCloseKey( hKey );
}
if (!ret && RegOpenKeyW( HKEY_CURRENT_USER, lpRegKey, &hKey ) == ERROR_SUCCESS)
{ {
ret = !RegQueryValueExW( hKey, lpValName, NULL, &type, lpBuf, &count); ret = !RegQueryValueExW( hKey, lpValName, NULL, &type, lpBuf, &count );
RegCloseKey( hKey ); RegCloseKey( hKey );
} }
return ret; return ret;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment