mirror of
https://git.proxmox.com/git/libgit2
synced 2025-07-06 01:49:24 +00:00
Fix failure in win32_find_git_in_registry() when UAC is turned on
Demand read only access to registry key instead of full access. This might happen in Windows Vista and later.
This commit is contained in:
parent
ffbd337aef
commit
89095fbddc
@ -132,7 +132,7 @@ static int win32_find_git_in_registry(
|
||||
|
||||
path16.len = MAX_PATH;
|
||||
|
||||
if (RegOpenKeyExW(hieve, key, 0, KEY_ALL_ACCESS, &hKey) == ERROR_SUCCESS) {
|
||||
if (RegOpenKeyExW(hieve, key, 0, KEY_READ, &hKey) == ERROR_SUCCESS) {
|
||||
if (RegQueryValueExW(hKey, L"InstallLocation", NULL, &dwType,
|
||||
(LPBYTE)&path16.path, &path16.len) == ERROR_SUCCESS)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user