summaryrefslogtreecommitdiff
path: root/src/win32
diff options
context:
space:
mode:
authorLinquize <linquize@yahoo.com.hk>2013-09-17 22:57:06 +0800
committerLinquize <linquize@yahoo.com.hk>2013-09-17 22:57:06 +0800
commitffbd337aefae76a646bafd6e5f3c1edc18400f05 (patch)
tree4f827782b8cf9091b4254517b934d944c92bdf6d /src/win32
parentefc9e6700fabc91ea490fcc5ea034b51648c9e88 (diff)
downloadlibgit2-ffbd337aefae76a646bafd6e5f3c1edc18400f05.tar.gz
Fix failure in win32_find_git_in_registry()
The buffer size 0 was definitely not enough so it failed
Diffstat (limited to 'src/win32')
-rw-r--r--src/win32/findfile.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/win32/findfile.c b/src/win32/findfile.c
index a1c11fcfb..eb83178a5 100644
--- a/src/win32/findfile.c
+++ b/src/win32/findfile.c
@@ -130,7 +130,7 @@ static int win32_find_git_in_registry(
assert(buf);
- path16.len = 0;
+ path16.len = MAX_PATH;
if (RegOpenKeyExW(hieve, key, 0, KEY_ALL_ACCESS, &hKey) == ERROR_SUCCESS) {
if (RegQueryValueExW(hKey, L"InstallLocation", NULL, &dwType,